From 22b3a8af49dc16bf5d8f9c3ce48b4770505ea33b Mon Sep 17 00:00:00 2001 From: IRONM00N <64110067+IRONM00N@users.noreply.github.com> Date: Wed, 6 Jul 2022 20:28:04 +0200 Subject: remove array from add*(...) --- src/lib/common/ButtonPaginator.ts | 4 ++-- src/lib/common/ConfirmationPrompt.ts | 4 ++-- src/lib/common/DeleteButton.ts | 4 ++-- 3 files changed, 6 insertions(+), 6 deletions(-) (limited to 'src/lib/common') diff --git a/src/lib/common/ButtonPaginator.ts b/src/lib/common/ButtonPaginator.ts index ed6743e..02c78ea 100644 --- a/src/lib/common/ButtonPaginator.ts +++ b/src/lib/common/ButtonPaginator.ts @@ -154,7 +154,7 @@ export class ButtonPaginator { * @returns The generated {@link ActionRow} */ protected getPaginationRow(disableAll = false) { - return new ActionRowBuilder().addComponents([ + return new ActionRowBuilder().addComponents( new ButtonBuilder({ style: ButtonStyle.Primary, customId: 'paginate_beginning', @@ -185,7 +185,7 @@ export class ButtonPaginator { emoji: PaginateEmojis.END, disabled: disableAll || this.curPage === this.numPages - 1 }) - ]); + ); } /** diff --git a/src/lib/common/ConfirmationPrompt.ts b/src/lib/common/ConfirmationPrompt.ts index 4bea092..b87d9ef 100644 --- a/src/lib/common/ConfirmationPrompt.ts +++ b/src/lib/common/ConfirmationPrompt.ts @@ -16,10 +16,10 @@ export class ConfirmationPrompt { */ protected async send(): Promise { this.messageOptions.components = [ - new ActionRowBuilder().addComponents([ + new ActionRowBuilder().addComponents( new ButtonBuilder({ style: ButtonStyle.Success, customId: 'confirmationPrompt_confirm', label: 'Yes' }), new ButtonBuilder({ style: ButtonStyle.Danger, customId: 'confirmationPrompt_cancel', label: 'No' }) - ]) + ) ]; const msg = await this.message.channel!.send(this.messageOptions); diff --git a/src/lib/common/DeleteButton.ts b/src/lib/common/DeleteButton.ts index 556bc07..340d07f 100644 --- a/src/lib/common/DeleteButton.ts +++ b/src/lib/common/DeleteButton.ts @@ -53,14 +53,14 @@ export class DeleteButton { */ protected updateComponents(edit = false, disable = false): void { this.messageOptions.components = [ - new ActionRowBuilder().addComponents([ + new ActionRowBuilder().addComponents( new ButtonBuilder({ style: ButtonStyle.Primary, customId: 'paginate__stop', emoji: PaginateEmojis.STOP, disabled: disable }) - ]) + ) ]; if (edit) { this.messageOptions.reply = undefined; -- cgit