Skip to content

Commit

Permalink
🐛 Fix: fix upload failed error of aliyun upyun and github
Browse files Browse the repository at this point in the history
  • Loading branch information
Kuingsmile committed Aug 31, 2023
1 parent 0eb7bac commit 320ac73
Show file tree
Hide file tree
Showing 3 changed files with 6 additions and 6 deletions.
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -68,7 +68,7 @@
"mitt": "^3.0.1",
"node-ssh-no-cpu-features": "^1.0.1",
"nodejs-file-downloader": "^4.12.1",
"piclist": "^1.0.0",
"piclist": "^1.0.1",
"pinia": "^2.1.6",
"pinia-plugin-persistedstate": "^3.2.0",
"qiniu": "^7.9.0",
Expand Down
2 changes: 1 addition & 1 deletion src/main/manage/apis/upyun.ts
Original file line number Diff line number Diff line change
Expand Up @@ -59,7 +59,7 @@ class UpyunApi {
}

getAntiLeechParam (key: string): string {
const uri = `/${encodeURIComponent(key)}`.replace(/%2F/g, '/').replace(/^\/+/g, '/')
const uri = `/${key}`.replace(/%2F/g, '/').replace(/^\/+/g, '/')
const now = Math.round(new Date().getTime() / 1000)
const expire = this.expireTime ? now + parseInt(this.expireTime.toString(), 10) : now + 1800
const sign = md5(`${this.antiLeechToken}&${expire}&${uri}`, 'hex')
Expand Down
8 changes: 4 additions & 4 deletions yarn.lock
Original file line number Diff line number Diff line change
Expand Up @@ -12488,10 +12488,10 @@ performance-now@^2.1.0:
resolved "https://registry.npmmirror.com/performance-now/-/performance-now-2.1.0.tgz#6309f4e0e5fa913ec1c69307ae364b4b377c9e7b"
integrity sha512-7EAHlyLHI56VEIdK57uwHdHKIaAGbnXPiw0yWbarQZOKaKpvUIgW0jWRVLiatnM+XXlSwsanIBH/hzGMJulMow==

piclist@^1.0.0:
version "1.0.0"
resolved "https://registry.npmjs.org/piclist/-/piclist-1.0.0.tgz#71674a3905e77c9325d5cda6529e025253df15b0"
integrity sha512-8KP+9gZOCZpQOZIRIFVO/WeWv8kjY0GOo3bTskF8BAaQfUl6lJi2AkG435nVDSfKidt14v53ZfohNn3jpXX9Hg==
piclist@^1.0.1:
version "1.0.1"
resolved "https://registry.npmjs.org/piclist/-/piclist-1.0.1.tgz#6d15ec44393de38b32ba34d041511324ec7dda55"
integrity sha512-c68ijE5Gj3E29KEc1B6F75pluldHLJvkvYmoWhNpYg1hOXGTlxepZCZm8Wp/a9NVjT8jh3zfX1fmpbFGjpOOug==
dependencies:
"@picgo/i18n" "^1.0.0"
"@picgo/store" "^2.0.4"
Expand Down

0 comments on commit 320ac73

Please sign in to comment.