Closed DragonCat4012 closed 1 year ago
imageurl options removed displayAvatarURL({ format: "png" }) -> displayAvatarURL()
displayAvatarURL({ format: "png" }) -> displayAvatarURL()
loading/savcing via axios/fs works
const imageResponse = await axios.get(url, { responseType: 'arraybuffer', }); const outputFileName = `yourfilenamehere.png` fs.createWriteStream(outputFileName).write(imageResponse.data); return img
image: message.author.displayAvatarURL().replace('webp','png') draws card without avatar
https://stackoverflow.com/questions/20660036/node-js-canvas-image-given-has-not-completed-loading
https://stackoverflow.com/questions/65076410/how-to-convert-a-remote-webp-image-to-a-png-image-to-load-it-into-node-canvas
The syntax of displayAvatarURL({ format: "png" }) was changed to displayAvatarURL({ extension: "png" }). This issue is resolved as of Commit d59e65a and v4.9.0
displayAvatarURL({ format: "png" })
displayAvatarURL({ extension: "png" })
draw card function
imageurl options removed
displayAvatarURL({ format: "png" }) -> displayAvatarURL()
loading/savcing via axios/fs works
image: message.author.displayAvatarURL().replace('webp','png') draws card without avatar