Skip to content

Commit

Permalink
修改上传成功没有回调bug
Browse files Browse the repository at this point in the history
  • Loading branch information
tywei90 committed Jan 8, 2018
1 parent f941ca2 commit 4af1e31
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions server/common/upload.js
Original file line number Diff line number Diff line change
Expand Up @@ -53,9 +53,9 @@ function minImage(fileInfo, callback) {
ImageminPngquant({quality: '65-80'})
]
}).then(files => {
console.log(files);
callback(1, fileInfo);
}).catch(function(err){
callback(err ? 0 : 1, fileInfo);
callback(0, fileInfo);
});
}

Expand Down

0 comments on commit 4af1e31

Please sign in to comment.