From 376aeef0012da785f30cabfc1478c8c0b174904b Mon Sep 17 00:00:00 2001 From: Dirain1700 <86363603+Dirain1700@users.noreply.github.com> Date: Tue, 6 Jun 2023 23:16:36 +0000 Subject: [PATCH] more minimizing --- src/rooms.ts | 5 ----- src/tournaments.ts | 2 ++ 2 files changed, 2 insertions(+), 5 deletions(-) diff --git a/src/rooms.ts b/src/rooms.ts index 4e11c4ae..ef707bd0 100644 --- a/src/rooms.ts +++ b/src/rooms.ts @@ -898,11 +898,6 @@ export class Room { }); } - onTournamentCreateError(reason: string): void { - Tournaments.onTournamentCreateError(this, reason); - if (this.searchChallenge) this.searchChallenge.end(); - } - startHangman(answer: string, hint: string, user: User): void { this.say("/hangman create " + answer + ", " + hint, { dontCheckFilter: true, diff --git a/src/tournaments.ts b/src/tournaments.ts index da10c8c8..10c9fe59 100644 --- a/src/tournaments.ts +++ b/src/tournaments.ts @@ -374,6 +374,8 @@ export class Tournaments { onTournamentCreateError(room: Room, reason: string): void { room.say("Could not create a tournament: " + reason); + + if (room.searchChallenge) room.searchChallenge.end(); } resolveFormatFromInput(originalTargets: readonly string[], room?: Room): string | IFormat {