Dont need to change manually the number of picture
This commit is contained in:
parent
b386608936
commit
033dd7345b
2 changed files with 2 additions and 2 deletions
|
@ -11,7 +11,7 @@ module.exports = class BadmemeCommand extends Command {
|
||||||
}
|
}
|
||||||
|
|
||||||
run(message) {
|
run(message) {
|
||||||
const number = 12;
|
const number = object.keys(responseObject).lenght;
|
||||||
const picNumber = Math.floor (Math.random() * (number - 1 + 1)) + 1;
|
const picNumber = Math.floor (Math.random() * (number - 1 + 1)) + 1;
|
||||||
message.channel.send(`${picNumber}: ${responseObject[picNumber]}`);
|
message.channel.send(`${picNumber}: ${responseObject[picNumber]}`);
|
||||||
}
|
}
|
||||||
|
|
|
@ -11,7 +11,7 @@ module.exports = class DespacitoCommand extends Command {
|
||||||
}
|
}
|
||||||
|
|
||||||
run(message) {
|
run(message) {
|
||||||
const number = 5;
|
const number = object.keys(responseObject).lenght;
|
||||||
const vidNumber = Math.floor (Math.random() * (number - 1 + 1)) + 1;
|
const vidNumber = Math.floor (Math.random() * (number - 1 + 1)) + 1;
|
||||||
message.channel.send(`${vidNumber}: ${responseObject[vidNumber]}`);
|
message.channel.send(`${vidNumber}: ${responseObject[vidNumber]}`);
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue