mirror of
https://github.com/cosmos/cosmjs.git
synced 2025-03-10 21:49:15 +00:00
Using push instead of unshift
This commit is contained in:
parent
03f783194f
commit
d4b382a1af
@ -347,7 +347,7 @@ export class CosmWasmClient {
|
||||
const { contracts, pagination }: QueryContractsByCodeResponse =
|
||||
await this.forceGetQueryClient().wasm.listContractsByCodeId(codeId, startAtKey);
|
||||
const loadedContracts = contracts || [];
|
||||
allContracts.unshift(...loadedContracts);
|
||||
allContracts.push(...loadedContracts);
|
||||
startAtKey = pagination?.nextKey;
|
||||
} while (startAtKey?.length !== 0 && startAtKey !== undefined);
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user