gpake / qiniu-wxapp-sdk

qiniu SDK based on wxapp
GNU General Public License v3.0
703 stars 278 forks source link

关于key的问题 #4

Closed hosven closed 7 years ago

hosven commented 7 years ago

qiniu的默认是:不设置key时,自动生成qiniu的etag来作为key,可以消重。 请问这个sdk要修改哪里才能达到这种效果。

如果按现在的默认设置使用微信的filepath来做key的话,就无法在qiniu消重了。

非常感谢

hosven commented 7 years ago

找到了! 将这个'key'注释掉

var formData = { 'token': config.qiniuUploadToken, // 'key': fileName };

gpake commented 7 years ago

多谢提醒,我没有考虑到这个问题。接下来加上

gpake commented 7 years ago

@hosven, Hey 096146414e71a58dc98d8fcfa065657269fe637c there is my solution, a new key [shouldUseQiniuFileName: bool] in options to determine wechat filename or qiniu