mirror of
https://github.com/arthur-pbty/xiao.git
synced 2026-06-27 14:18:36 +02:00
Fix all eslint v9 issues
This commit is contained in:
@@ -27,7 +27,6 @@ module.exports = class AlertCommand extends Command {
|
||||
name: 'The Hill',
|
||||
url: 'https://thehill.com/',
|
||||
reason: 'Image',
|
||||
// eslint-disable-next-line max-len
|
||||
reasonURL: 'https://thehill.com/policy/technology/409737-this-is-a-test-us-officials-test-presidential-alert'
|
||||
}
|
||||
],
|
||||
|
||||
@@ -32,7 +32,6 @@ module.exports = class ChiIdeaCommand extends Command {
|
||||
name: 'Inside Scanlation',
|
||||
url: 'https://www.insidescanlation.com/',
|
||||
reason: 'Wild Words Font',
|
||||
// eslint-disable-next-line max-len
|
||||
reasonURL: 'https://www.insidescanlation.com/etc/the-idiots-guide-to-editing-manga/guide/type/fonts.html'
|
||||
}
|
||||
],
|
||||
|
||||
@@ -21,7 +21,6 @@ module.exports = class RawCommand extends Command {
|
||||
name: 'Inside Scanlation',
|
||||
url: 'https://www.insidescanlation.com/',
|
||||
reason: 'Wild Words Font',
|
||||
// eslint-disable-next-line max-len
|
||||
reasonURL: 'https://www.insidescanlation.com/etc/the-idiots-guide-to-editing-manga/guide/type/fonts.html'
|
||||
}
|
||||
],
|
||||
|
||||
@@ -158,7 +158,7 @@ module.exports = class ChessCommand extends Command {
|
||||
if (alreadySaved) {
|
||||
await msg.say('You already have a saved game, do you want to overwrite it?');
|
||||
const verification = await verify(msg.channel, author);
|
||||
if (!verification) continue; // eslint-disable-line max-depth
|
||||
if (!verification) continue;
|
||||
}
|
||||
if (gameState.turn === 'black') blackTime -= new Date() - now;
|
||||
if (gameState.turn === 'white') whiteTime -= new Date() - now;
|
||||
|
||||
@@ -109,7 +109,7 @@ module.exports = class NimCommand extends Command {
|
||||
time: 60000
|
||||
});
|
||||
if (!rowTurn.size) {
|
||||
if (lastTurnTimeout) { // eslint-disable-line max-depth
|
||||
if (lastTurnTimeout) {
|
||||
winner = 'time';
|
||||
break;
|
||||
} else {
|
||||
|
||||
@@ -72,7 +72,7 @@ module.exports = class HangmanCommand extends Command {
|
||||
} else if (word.includes(choice)) {
|
||||
displayText = true;
|
||||
for (let i = 0; i < word.length; i++) {
|
||||
if (word.charAt(i) !== choice) continue; // eslint-disable-line max-depth
|
||||
if (word.charAt(i) !== choice) continue;
|
||||
confirmation.push(word.charAt(i));
|
||||
display[i] = word.charAt(i);
|
||||
}
|
||||
@@ -112,7 +112,7 @@ module.exports = class HangmanCommand extends Command {
|
||||
partOfSpeech: data.fl,
|
||||
definiton: data.shortdef.map((definition, i) => `(${i + 1}) ${definition}`).join('\n')
|
||||
};
|
||||
} catch (err) {
|
||||
} catch {
|
||||
return null;
|
||||
}
|
||||
}
|
||||
|
||||
@@ -26,7 +26,6 @@ module.exports = class HorseRaceCommand extends Command {
|
||||
name: 'Ambition',
|
||||
url: 'https://ambition.com/',
|
||||
reason: 'Image',
|
||||
// eslint-disable-next-line max-len
|
||||
reasonURL: 'https://help.ambition.com/hc/en-us/articles/360005048011-How-do-I-set-up-a-Leaderboard-Slide-'
|
||||
},
|
||||
{
|
||||
|
||||
@@ -37,7 +37,6 @@ module.exports = class WhosThatPokemonCryCommand extends Command {
|
||||
name: 'u/CaptainRako',
|
||||
url: 'https://www.reddit.com/user/CaptainRako/',
|
||||
reason: 'Background Image',
|
||||
// eslint-disable-next-line max-len
|
||||
reasonURL: 'https://www.reddit.com/r/pokemon/comments/420xiv/whos_that_pokemon_1920x1080_hd_template_i_just/'
|
||||
},
|
||||
{
|
||||
|
||||
@@ -44,7 +44,6 @@ module.exports = class WhosThatPokemonCommand extends Command {
|
||||
name: 'u/CaptainRako',
|
||||
url: 'https://www.reddit.com/user/CaptainRako/',
|
||||
reason: 'Background Image',
|
||||
// eslint-disable-next-line max-len
|
||||
reasonURL: 'https://www.reddit.com/r/pokemon/comments/420xiv/whos_that_pokemon_1920x1080_hd_template_i_just/'
|
||||
},
|
||||
{
|
||||
|
||||
@@ -32,7 +32,7 @@ module.exports = class NameRaterCommand extends Command {
|
||||
const user = await this.client.users.fetch(matches[1]);
|
||||
if (!user) return false;
|
||||
return true;
|
||||
} catch (err) {
|
||||
} catch {
|
||||
return false;
|
||||
}
|
||||
}
|
||||
|
||||
@@ -1,9 +1,9 @@
|
||||
// Credit: https://github.com/discordjs/Commando/blob/master/src/commands/util/eval.js
|
||||
const util = require('util');
|
||||
/* eslint-disable no-unused-vars, prefer-destructuring */
|
||||
/* eslint-disable no-unused-vars */
|
||||
const discord = require('discord.js');
|
||||
const Util = require('../../util/Util');
|
||||
/* eslint-enable no-unused-vars, prefer-destructuring */
|
||||
/* eslint-enable no-unused-vars */
|
||||
const tags = require('common-tags');
|
||||
const Command = require('../../framework/Command');
|
||||
|
||||
|
||||
Reference in New Issue
Block a user