From f21db44611bfc911cfd4ec412a7db5c6fd97b2c7 Mon Sep 17 00:00:00 2001 From: tema Date: Tue, 9 Sep 2025 16:13:17 +0900 Subject: [PATCH] Lint fixes --- apps/bff/src/vendors/freebit/freebit.service.ts | 12 +++++++++--- apps/portal/scripts/dev-prep.mjs | 2 +- .../app/subscriptions/[id]/sim/change-plan/page.tsx | 2 +- .../src/app/subscriptions/[id]/sim/top-up/page.tsx | 2 +- .../src/components/layout/dashboard-layout.tsx | 4 ++-- .../sim-management/components/SimFeatureToggles.tsx | 5 ++++- .../components/SimManagementSection.tsx | 13 ++++++++----- .../sim-management/components/TopUpModal.tsx | 2 +- 8 files changed, 27 insertions(+), 15 deletions(-) diff --git a/apps/bff/src/vendors/freebit/freebit.service.ts b/apps/bff/src/vendors/freebit/freebit.service.ts index 4b803b77..1c6df0c3 100644 --- a/apps/bff/src/vendors/freebit/freebit.service.ts +++ b/apps/bff/src/vendors/freebit/freebit.service.ts @@ -152,7 +152,7 @@ export class FreebititService { T extends { resultCode: string | number; status?: { message?: string; statusCode?: string | number }; - } + }, >(endpoint: string, data: unknown): Promise { const authKey = await this.getAuthKey(); const requestData = { ...(data as Record), authKey }; @@ -320,7 +320,11 @@ export class FreebititService { }; const datas = response.responseDatas as unknown; - const list = Array.isArray(datas) ? (datas as AcctDetailItem[]) : datas ? [datas as AcctDetailItem] : []; + const list = Array.isArray(datas) + ? (datas as AcctDetailItem[]) + : datas + ? [datas as AcctDetailItem] + : []; if (!list.length) { throw new BadRequestException("No SIM details found for this account"); } @@ -525,7 +529,9 @@ export class FreebititService { return history; } catch (error: unknown) { const message = error instanceof Error ? error.message : String(error); - this.logger.error(`Failed to get SIM top-up history for account ${account}`, { error: message }); + this.logger.error(`Failed to get SIM top-up history for account ${account}`, { + error: message, + }); throw error as Error; } } diff --git a/apps/portal/scripts/dev-prep.mjs b/apps/portal/scripts/dev-prep.mjs index 283787ae..37a705fc 100644 --- a/apps/portal/scripts/dev-prep.mjs +++ b/apps/portal/scripts/dev-prep.mjs @@ -1,6 +1,6 @@ #!/usr/bin/env node /* eslint-env node */ -/* eslint-disable no-console */ + // Ensure dev-time Next.js manifests exist to avoid noisy ENOENT errors import { mkdirSync, existsSync, writeFileSync } from "fs"; import { join } from "path"; diff --git a/apps/portal/src/app/subscriptions/[id]/sim/change-plan/page.tsx b/apps/portal/src/app/subscriptions/[id]/sim/change-plan/page.tsx index 9eb06447..c4aebed3 100644 --- a/apps/portal/src/app/subscriptions/[id]/sim/change-plan/page.tsx +++ b/apps/portal/src/app/subscriptions/[id]/sim/change-plan/page.tsx @@ -79,7 +79,7 @@ export default function SimChangePlanPage() { )} -
void submit(e)} className="space-y-6"> + void submit(e)} className="space-y-6">