mirror of
https://github.com/arthur-pbty/xiao.git
synced 2026-06-26 14:19:11 +02:00
Beep
This commit is contained in:
@@ -12,7 +12,7 @@ module.exports = class InvertCommand extends Command {
|
||||
description: 'Draws an image or a user\'s avatar but inverted.',
|
||||
throttling: {
|
||||
usages: 1,
|
||||
duration: 15
|
||||
duration: 10
|
||||
},
|
||||
clientPermissions: ['ATTACH_FILES'],
|
||||
args: [
|
||||
@@ -20,19 +20,13 @@ module.exports = class InvertCommand extends Command {
|
||||
key: 'image',
|
||||
prompt: 'What image would you like to edit?',
|
||||
type: 'image',
|
||||
default: ''
|
||||
default: msg => msg.author.displayAvatarURL({ format: 'png', size: 512 })
|
||||
}
|
||||
]
|
||||
});
|
||||
}
|
||||
|
||||
async run(msg, { image }) {
|
||||
if (!image) {
|
||||
image = msg.author.displayAvatarURL({
|
||||
format: 'png',
|
||||
size: 512
|
||||
});
|
||||
}
|
||||
try {
|
||||
const { body } = await snekfetch.get(image);
|
||||
const data = await loadImage(body);
|
||||
|
||||
Reference in New Issue
Block a user