Compare commits

...
2 Commits
Author SHA1 Message Date
Molunerfinn 9ef615cab4 1.4.3 2018-03-12 11:03:27 +08:00
Molunerfinn fb236c3186 Fixed: qiniu uploader path undefined 2018-03-12 11:01:14 +08:00
2 changed files with 2 additions and 2 deletions
+1 -1
View File
@@ -1,6 +1,6 @@
{ {
"name": "picgo", "name": "picgo",
"version": "1.4.2", "version": "1.4.3",
"author": "Molunerfinn <marksz@teamsz.xyz>", "author": "Molunerfinn <marksz@teamsz.xyz>",
"description": "Easy to upload your pic & copy to write", "description": "Easy to upload your pic & copy to write",
"license": "MIT", "license": "MIT",
+1 -1
View File
@@ -6,7 +6,7 @@ import { Notification } from 'electron'
function postOptions (fileName, token, imgBase64) { function postOptions (fileName, token, imgBase64) {
const area = selectArea(db.read().get('picBed.qiniu.area').value() || 'z0') const area = selectArea(db.read().get('picBed.qiniu.area').value() || 'z0')
const path = db.read().get('picBed.qiniu.path') || '' const path = db.read().get('picBed.qiniu.path').value() || ''
const base64FileName = Buffer.from(path + fileName, 'utf-8').toString('base64').replace(/\+/g, '-').replace(/\//g, '_') const base64FileName = Buffer.from(path + fileName, 'utf-8').toString('base64').replace(/\+/g, '-').replace(/\//g, '_')
return { return {
method: 'POST', method: 'POST',