From ff893437950128d100ae9835310c36be1f0fea06 Mon Sep 17 00:00:00 2001 From: Claude Date: Wed, 20 May 2026 01:11:28 +0000 Subject: [PATCH] Fix lint: move shouldAppendDraftSlots to outer scope oxlint (consistent-function-scoping) requires functions that don't close over any variables to be defined at the outer scope rather than inside a describe block. https://claude.ai/code/session_01M3H55gnMxRztJK9KMXqqZo --- app/routes/leagues/__tests__/settings-update.test.ts | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/app/routes/leagues/__tests__/settings-update.test.ts b/app/routes/leagues/__tests__/settings-update.test.ts index 56d0c1d..059fa49 100644 --- a/app/routes/leagues/__tests__/settings-update.test.ts +++ b/app/routes/leagues/__tests__/settings-update.test.ts @@ -463,11 +463,11 @@ describe('Settings Update - Team Count Changes', () => { // Mirrors the server action condition: existingSlots.length === currentTeamCount // --------------------------------------------------------------------------- -describe('Settings Update - Draft Slot Creation Guard', () => { - function shouldAppendDraftSlots(existingSlotsCount: number, currentTeamCount: number): boolean { - return existingSlotsCount === currentTeamCount; - } +function shouldAppendDraftSlots(existingSlotsCount: number, currentTeamCount: number): boolean { + return existingSlotsCount === currentTeamCount; +} +describe('Settings Update - Draft Slot Creation Guard', () => { it('does not create slots when no draft order was ever set', () => { expect(shouldAppendDraftSlots(0, 12)).toBe(false); });