-
Notifications
You must be signed in to change notification settings - Fork 260
feat: use latest initiad & initia.js #1783
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: main
Are you sure you want to change the base?
Conversation
|
Review the following changes in direct dependencies. Learn more about Socket for GitHub.
|
PR SummaryUpdates Initia support and OFT tooling, plus minor configs/docs.
Written by Cursor Bugbot for commit 2fd6c64. This will update automatically on new commits. Configure here. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Cursor Bugbot has reviewed your changes and found 2 potential issues.
| signerOrProvider: signer, | ||
| }), | ||
| protected readonly apiKit = new SafeApiKit({ txServiceUrl: safeUrl, apiKey: safeConfig.safeApiKey, chainId }), | ||
| protected readonly apiKit = new SafeApiKit({ txServiceUrl: safeUrl, ethAdapter }), |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
SafeApiKit constructor uses deprecated/invalid API parameters
High Severity
The SafeApiKit constructor changed from using chainId and apiKey to using ethAdapter. However, the package uses @safe-global/api-kit version ~4.0.0, which requires chainId as a mandatory parameter and does not accept ethAdapter. The ethAdapter pattern was deprecated in SafeApiKit v2.x. This will cause the Gnosis Safe multisig functionality to fail at runtime when instantiating the GnosisOmniSignerEVM class.
| const to = ethers.utils.hexZeroPad(args.to, 32) | ||
| const amount = args.amount | ||
| const minAmount = args.min_amount | ||
| const sendingNativeToken = args.native_token ? true : false |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Boolean CLI flag incorrectly parses string "false" as true
High Severity
The --native-token CLI argument is parsed using args.native_token ? true : false, which treats the string "false" as truthy. If a user explicitly passes --native-token false, sendingNativeToken will be true because non-empty strings are truthy in JavaScript. This causes the transaction to include the token amount in the ETH value when the user explicitly tried to disable native token sending. The correct pattern used elsewhere in the codebase is args.xxx === 'true'.
Summary of Changes