|
@ -313,7 +313,6 @@ async function generateRound(message) { |
|
|
} |
|
|
} |
|
|
}); |
|
|
}); |
|
|
let i; |
|
|
let i; |
|
|
let generatingMsg = await message.channel.send("Generating..."); |
|
|
|
|
|
for (i = 1; i < 26; i++) { |
|
|
for (i = 1; i < 26; i++) { |
|
|
let tossup_question; |
|
|
let tossup_question; |
|
|
let question_category; |
|
|
let question_category; |
|
@ -356,6 +355,8 @@ async function generateRound(message) { |
|
|
bonus_answer + |
|
|
bonus_answer + |
|
|
"<br><br>"; |
|
|
"<br><br>"; |
|
|
htmlContent = htmlContent.replace(/\n/g, "<br>"); |
|
|
htmlContent = htmlContent.replace(/\n/g, "<br>"); |
|
|
|
|
|
}); |
|
|
|
|
|
} |
|
|
newGeneratedRound = new generatedRound({ |
|
|
newGeneratedRound = new generatedRound({ |
|
|
htmlContent: htmlContent, |
|
|
htmlContent: htmlContent, |
|
|
requestedBy: message.author.tag, |
|
|
requestedBy: message.author.tag, |
|
@ -365,10 +366,6 @@ async function generateRound(message) { |
|
|
? console.log("Error creating saving generated round content") |
|
|
? console.log("Error creating saving generated round content") |
|
|
: console.log("Sucessfully created new entry for the generated round") |
|
|
: console.log("Sucessfully created new entry for the generated round") |
|
|
); |
|
|
); |
|
|
}); |
|
|
|
|
|
if (generatingMsg) { |
|
|
|
|
|
generatingMsg.delete({ timeout: 100 }).catch(console.error); |
|
|
|
|
|
} |
|
|
|
|
|
message.channel.send("Check database"); |
|
|
message.channel.send("Check database"); |
|
|
} |
|
|
} |
|
|
|
|
|
|
|
|