]> git.codecow.com Git - libnemo.git/commitdiff
Fix frontier block contents checks.
authorChris Duncan <chris@codecow.com>
Tue, 4 Aug 2026 14:45:48 +0000 (07:45 -0700)
committerChris Duncan <chris@codecow.com>
Tue, 4 Aug 2026 14:45:48 +0000 (07:45 -0700)
src/lib/account/refresh.ts

index ae964f35ef29889d05f3f0372353025918cebeef..b79dd4599beb1370d956ca0b1de67309cbd55ad3 100644 (file)
@@ -46,7 +46,7 @@ export async function _refresh (account: Account, rpc: unknown): Promise<void> {
                throw new Error('Confirmed frontier block info subtype not found')
        }
        const confirmedFrontierSubtype = resConfirmedFrontierBlockInfo.subtype
-       if (!('contents' in resConfirmedFrontierBlockInfo) || resConfirmedFrontierBlockInfo.contents == null || !(typeof resConfirmedFrontierBlockInfo.contents !== 'object')) {
+       if (!('contents' in resConfirmedFrontierBlockInfo) || resConfirmedFrontierBlockInfo.contents == null || typeof resConfirmedFrontierBlockInfo.contents !== 'object') {
                throw new Error('Confirmed frontier block info contents not found')
        }
        const confirmedFrontierContents: Record<string, string> = {}
@@ -74,7 +74,7 @@ export async function _refresh (account: Account, rpc: unknown): Promise<void> {
                throw new Error('Frontier block info subtype not found')
        }
        const frontierSubtype = resFrontierBlockInfo.subtype
-       if (!('contents' in resFrontierBlockInfo) || resFrontierBlockInfo.contents == null || !(typeof resFrontierBlockInfo.contents !== 'object')) {
+       if (!('contents' in resFrontierBlockInfo) || resFrontierBlockInfo.contents == null || typeof resFrontierBlockInfo.contents !== 'object') {
                throw new Error('Frontier block info contents not found')
        }
        const frontierContents: Record<string, string> = {}