We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
2 parents b1cad73 + d04cdc2 commit d5af7b9Copy full SHA for d5af7b9
src/base.js
@@ -854,7 +854,7 @@ class Base {
854
return download.getBufferAndType(avatarUrl).then(({buffer, type})=> {
855
let opts = {
856
name: path.basename(avatarUrl),
857
- type.split(';')[0],
+ type,
858
rawResponse: false
859
};
860
return client.uploadContent(buffer, opts);
src/utils.js
@@ -36,6 +36,7 @@ const downloadGetBufferAndType = url => {
36
} else {
37
type = mime.lookup(urlParse(url).pathname);
38
}
39
+ type = type.split(';')[0];
40
return { buffer, type };
41
});
42
0 commit comments