Skip to content

Commit

Permalink
Fix lint. Add check for sdk within the config.
Browse files Browse the repository at this point in the history
  • Loading branch information
mariacarmina committed Oct 14, 2024
1 parent 591ab24 commit a79b137
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 2 deletions.
8 changes: 8 additions & 0 deletions src/config/ConfigHelper.ts
Original file line number Diff line number Diff line change
Expand Up @@ -331,6 +331,14 @@ export class ConfigHelper {
)
}

if (!('sdk' in config) || config.sdk === null) {
if (KNOWN_CONFIDENTIAL_EVMS.includes(config.chainId)) {
config.sdk = 'oasis'
} else {
config.sdk = 'evm'
}
}

Check failure on line 341 in src/config/ConfigHelper.ts

View workflow job for this annotation

GitHub Actions / lint

Delete `····`
config.accessListFactory = contractAddressesConfig.accessListFactory

config = { ...config, ...contractAddressesConfig }
Expand Down
4 changes: 2 additions & 2 deletions src/contracts/SmartContract.ts
Original file line number Diff line number Diff line change
Expand Up @@ -36,8 +36,8 @@ export abstract class SmartContract {

protected getSignerAccordingSdk() {
return this.config && 'sdk' in this.config && this.config.sdk === 'oasis'
? sapphire.wrap(this.signer)
: this.signer
? sapphire.wrap(this.signer)
: this.signer
}

/**
Expand Down

0 comments on commit a79b137

Please sign in to comment.