Fixing Roletip sendLBC call

Apparently despite being a supposedly smart language, JS still insists on making me convert a string of numbers from a number back to a string before _and_ inside a function call, yay aggressively dynamically typed languages.

This _should_ fix the matter now
This commit is contained in:
ProfessorDey 2018-03-20 17:18:30 +00:00 committed by GitHub
parent 44f4b4407f
commit db8d90b9a7
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -273,7 +273,7 @@ function doRoleTip(message, tipper, words, helpmsg) {
if (message.mentions.roles.first().members.first().id) { if (message.mentions.roles.first().members.first().id) {
let userIDs = message.mentions.roles.first().members.map(member => member.user.id.replace('!', '')); let userIDs = message.mentions.roles.first().members.map(member => member.user.id.replace('!', ''));
for (let i = 0; i < userIDs; i++) { for (let i = 0; i < userIDs; i++) {
sendLBC(message, tipper, userIDs[i], amount, prv); sendLBC(message, tipper, userIDs[i].toString(), amount, prv);
} }
} else { } else {
message.reply('Sorry, I could not find any users to tip in that role...').then(message => message.delete(5000)); message.reply('Sorry, I could not find any users to tip in that role...').then(message => message.delete(5000));