reason.text

This commit is contained in:
ChomeNS 2022-08-19 10:29:52 +07:00
parent d74480e1d5
commit becd6fcf16
2 changed files with 5 additions and 4 deletions

View file

@ -5,7 +5,7 @@ module.exports = {
'cbot ', 'cbot ',
'/cbot ', '/cbot ',
], ],
'useChat': true, 'useChat': false,
'core': { 'core': {
'layers': 1, 'layers': 1,
}, },

View file

@ -156,7 +156,6 @@ function main() {
try { try {
if (bot.queue[0]) { if (bot.queue[0]) {
try { try {
console.log(bot.queue[0]);
if (containsIllegalCharacters(bot.queue[0])) { if (containsIllegalCharacters(bot.queue[0])) {
bot.queue.shift(); bot.queue.shift();
return; return;
@ -393,8 +392,10 @@ function main() {
let timeout = 1000; let timeout = 1000;
try { try {
if (reason.text.find((data) => data.text === 'Wait 5 seconds before connecting, thanks! :)')) timeout = 1000 * 6; if (reason.text) {
if (reason.text.find((data) => data.text === 'You are logging in too fast, try again later.')) timeout = 1000 * 6; if (reason.text === 'Wait 5 seconds before connecting, thanks! :)') timeout = 1000 * 6;
if (reason.text === 'You are logging in too fast, try again later.') timeout = 1000 * 6;
}
} catch (e) { } catch (e) {
console.log(e.message); console.log(e.message);
} }