From 0a352bec162e834de33ce8f2243a36dcbc6aae56 Mon Sep 17 00:00:00 2001 From: TRACTION <19631364+iamtraction@users.noreply.github.com> Date: Sat, 28 Sep 2024 16:57:27 +0530 Subject: [PATCH] chore: linting Signed-off-by: TRACTION <19631364+iamtraction@users.noreply.github.com> --- src/commands/music/play.ts | 2 ++ src/commands/translate.ts | 1 + src/utils/strings.ts | 1 + 3 files changed, 4 insertions(+) diff --git a/src/commands/music/play.ts b/src/commands/music/play.ts index 1d3140a9b..09099a836 100644 --- a/src/commands/music/play.ts +++ b/src/commands/music/play.ts @@ -52,6 +52,8 @@ class PlayCommand extends Command { entersState(connection, VoiceConnectionStatus.Connecting, 5_000), ]); } catch (error) { + Logger.error(error); + // seems to be a real disconnect which SHOULDN'T be recovered from connection.destroy(); diff --git a/src/commands/translate.ts b/src/commands/translate.ts index cb968d135..095fe821a 100644 --- a/src/commands/translate.ts +++ b/src/commands/translate.ts @@ -4,6 +4,7 @@ */ import { ApplicationCommandOptionType, ChatInputCommandInteraction } from "discord.js"; import { Command } from "@bastion/tesseract"; +// eslint-disable-next-line @typescript-eslint/no-require-imports import translate = require("@iamtraction/google-translate"); class TranslateCommand extends Command { diff --git a/src/utils/strings.ts b/src/utils/strings.ts index 84b711ba9..745c8c256 100644 --- a/src/utils/strings.ts +++ b/src/utils/strings.ts @@ -2,6 +2,7 @@ * @author TRACTION (iamtraction) * @copyright 2022 */ +// eslint-disable-next-line no-constant-binary-expression const frequency = (string: string): { [key: string]: number } => [ ...string ].reduce((a: { [key: string]: number }, c) => (a[c] = a[c] + 1 || 1) && a, {}); const toTitleCase = (string: string, splitSeparator = " ", joinSeprator = " "): string => {