aboutsummaryrefslogtreecommitdiffstats
path: root/pixiv.js
diff options
context:
space:
mode:
authormitsugu oyama2010-12-06 15:56:19 +0900
committermitsugu oyama2010-12-06 15:56:19 +0900
commita0fac9a6fb5d0b77bdd153758248a28a211054ac (patch)
tree384e62dce0104a1b546a6f8bf1aa1ff3a04f0489 /pixiv.js
parentc7693384d0b8eff3ced8cc08ba5b455163006cd5 (diff)
downloadvimperator-plugins-a0fac9a6fb5d0b77bdd153758248a28a211054ac.tar.bz2
fix cant save image file ex. hogehoge.jpg?1038735
Diffstat (limited to 'pixiv.js')
-rw-r--r--pixiv.js3
1 files changed, 3 insertions, 0 deletions
diff --git a/pixiv.js b/pixiv.js
index e6e9bc2..2d5e7d1 100644
--- a/pixiv.js
+++ b/pixiv.js
@@ -128,6 +128,9 @@ commands.addUserCommand(
let truePixivImg=function(){
let fileName=imgUrl.substr(imgUrl.lastIndexOf('/'));
+ if (-1!=fileName.indexOf('?')){
+ fileName=fileName.substr(0,fileName.indexOf('?'));
+ }
let tmpPath=savePath+fileName;
let instream=xhrImg.responseText;
let aFile=Cc["@mozilla.org/file/local;1"]