From: Chris Duncan Date: Sat, 9 Aug 2025 06:24:02 +0000 (-0700) Subject: Reset account internal flag. X-Git-Tag: v0.10.5~41^2~160 X-Git-Url: https://git.codecow.com/?a=commitdiff_plain;h=0b44a12f087bb772ddbfa801a32e16587f2574ff;p=libnemo.git Reset account internal flag. --- diff --git a/src/lib/account.ts b/src/lib/account.ts index a0c719d..b01d265 100644 --- a/src/lib/account.ts +++ b/src/lib/account.ts @@ -53,8 +53,9 @@ export class Account { private constructor (address: string, publicKey: Key, index?: number) { if (!Account.#isInternal) { - throw new Error(`Account cannot be instantiated directly. Use factory methods instead.`) + throw new Error('Account cannot be instantiated directly. Use `import()` instead.') } + Account.#isInternal = false this.#address = address .replace(PREFIX, '') .replace(PREFIX_LEGACY, '')