Enable for-in lint rule (#3013)

### Description

https://eslint.org/docs/latest/rules/guard-for-in

### Drive-by changes

Fix lint error in SDK Sealevel adapter

### Backward compatibility

Yes
pull/3018/head
J M Rossy 11 months ago committed by GitHub
parent 7e620c9dfa
commit eb83cf891c
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
  1. 1
      .eslintrc
  2. 2
      typescript/sdk/src/ism/HyperlaneIsmFactory.ts
  3. 2
      typescript/sdk/src/token/adapters/SealevelTokenAdapter.ts

@ -23,6 +23,7 @@
"no-extra-boolean-cast": ["error"],
"no-ex-assign": ["error"],
"no-constant-condition": ["off"],
"guard-for-in": ["error"],
"@typescript-eslint/ban-ts-comment": ["off"],
"@typescript-eslint/explicit-module-boundary-types": ["off"],
"@typescript-eslint/no-explicit-any": ["off"],

@ -165,7 +165,7 @@ export class HyperlaneIsmFactory extends HyperlaneApp<ProxyFactoryFactories> {
// ? this.getContracts(chain).defaultFallbackRoutingIsmFactory
// : this.getContracts(chain).routingIsmFactory;
const isms: ChainMap<Address> = {};
for (const origin in config.domains) {
for (const origin of Object.keys(config.domains)) {
const ism = await this.deploy(chain, config.domains[origin], origin);
isms[origin] = ism.address;
}

@ -302,7 +302,7 @@ export abstract class SealevelHypTokenAdapter
return tx;
}
async getIgpKeys() {
async getIgpKeys(): Promise<KeyListParams['igp']> {
const tokenData = await this.getTokenAccountData();
if (!tokenData.interchain_gas_paymaster) return undefined;
const igpConfig = tokenData.interchain_gas_paymaster;

Loading…
Cancel
Save