From f518fb921473e72df0ae6c686c127d16d8b9780f Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E6=89=8B=E7=93=9C=E4=B8=80=E5=8D=81=E9=9B=AA?= Date: Thu, 14 Nov 2024 11:28:06 +0800 Subject: [PATCH] fix: readonly --- src/core/packet/utils/helper/miniAppHelper.ts | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/src/core/packet/utils/helper/miniAppHelper.ts b/src/core/packet/utils/helper/miniAppHelper.ts index a65f4e3c..66b9642a 100644 --- a/src/core/packet/utils/helper/miniAppHelper.ts +++ b/src/core/packet/utils/helper/miniAppHelper.ts @@ -9,10 +9,10 @@ import { type MiniAppTemplateNameList = "bili" | "weibo"; export abstract class MiniAppInfo { - static sdkId: string = "V1_PC_MINISDK_99.99.99_1_APP_A"; + static readonly sdkId: string = "V1_PC_MINISDK_99.99.99_1_APP_A"; template: MiniAppReqTemplateParams; - private static appMap = new Map(); + private static readonly appMap = new Map(); protected constructor(template: MiniAppReqTemplateParams) { this.template = template; @@ -22,7 +22,7 @@ export abstract class MiniAppInfo { return this.appMap.get(name); } - static Bili = new class extends MiniAppInfo { + static readonly Bili = new class extends MiniAppInfo { constructor() { super({ sdkId: MiniAppInfo.sdkId, @@ -40,7 +40,7 @@ export abstract class MiniAppInfo { } }; - static WeiBo = new class extends MiniAppInfo { + static readonly WeiBo = new class extends MiniAppInfo { constructor() { super({ sdkId: MiniAppInfo.sdkId,