From eca0369b46631e569129775af40e948980b62b45 Mon Sep 17 00:00:00 2001 From: Olexandr88 Date: Mon, 26 Jan 2026 11:40:40 +0200 Subject: [PATCH] chore: fix AccountSyncer mock array creation --- web-wallet/src/lib/__mocks__/AccountSyncer.js | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/web-wallet/src/lib/__mocks__/AccountSyncer.js b/web-wallet/src/lib/__mocks__/AccountSyncer.js index 8adb608e15..8675ff804f 100644 --- a/web-wallet/src/lib/__mocks__/AccountSyncer.js +++ b/web-wallet/src/lib/__mocks__/AccountSyncer.js @@ -16,10 +16,10 @@ class AccountSyncerMock extends AccountSyncer { * @returns {Promise} */ async balances(profiles) { - return Array(profiles.length).fill({ + return Array.from({ length: profiles.length }, () => ({ nonce: 9876n, value: 12_345_000_000_000n, - }); + })); } /** @@ -27,7 +27,7 @@ class AccountSyncerMock extends AccountSyncer { * @returns {Promise} */ async stakes(profiles) { - return Array(profiles.length).fill(stakeInfo); + return Array.from({ length: profiles.length }, () => stakeInfo); } }