Skip to content

Commit

Permalink
Cleanup nits
Browse files Browse the repository at this point in the history
  • Loading branch information
TarikGul committed Sep 18, 2024
1 parent 98892ad commit 87e814d
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 4 deletions.
6 changes: 3 additions & 3 deletions packages/api-cli/src/runcli.ts
Original file line number Diff line number Diff line change
Expand Up @@ -252,13 +252,13 @@ async function makeTx ({ api, fn, log }: CallInfo): Promise<(() => void) | Hash>
let signable;

if (sudo || sudoUncheckedWeight) {
const adminId = await api.query.sudo.key();
const adminId = await api.query['sudo']['key']();

assert(adminId.eq(signer.address), 'Supplied seed does not match on-chain sudo key');

signable = sudoUncheckedWeight
? api.tx.sudo.sudoUncheckedWeight(fn(...params), sudoUncheckedWeight)
: api.tx.sudo.sudo(fn(...params));
? api.tx['sudo']['sudoUncheckedWeight'](fn(...params), sudoUncheckedWeight)
: api.tx['sudo']['sudo'](fn(...params));
} else {
signable = fn(...params);
}
Expand Down
2 changes: 1 addition & 1 deletion packages/json-serve/src/runcli.ts
Original file line number Diff line number Diff line change
Expand Up @@ -115,7 +115,7 @@ async function main (): Promise<void> {
tokenDecimals = chainProperties.tokenDecimals.unwrapOr([new BN(12)])[0].toNumber();

await api.rpc.chain.subscribeNewHeads(onNewHead);
await api.query.balances.totalIssuance(onTotalInsurance);
await api.query['balances']['totalIssuance'](onTotalInsurance);
await api.derive.staking.electedInfo(undefined, undefined, onElectedInfo);
}

Expand Down

0 comments on commit 87e814d

Please sign in to comment.