-
Notifications
You must be signed in to change notification settings - Fork 1.2k
Refactor AA code to support more chains #5978
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
Conversation
✅ Deploy Preview for remixproject ready!
To edit notification comments on pull requests, go to your Netlify site configuration. |
} | ||
if (tx.fromSmartAccount && tx.value === "0" && err && err.error && err.error.indexOf('insufficient funds for transfer') !== -1) { | ||
// Do not show dialog for insufficient funds as smart account may be using paymaster | ||
if (tx.fromSmartAccount && tx.value === "0" && ( |
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.
I think we need to find a better way to check that...
below you are checking against err.error
and not err
..
should that be: err && err.error..indexOf('gas required exceeds allowance (0)')
?
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.
updated
async sendUserOp (tx) { | ||
async sendUserOp (tx, chainId) { | ||
// AA03: Add network name and public URL to support contract transactions using smart account | ||
const aaSupportedNetworks = { |
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.
these constants should be put in an helper, so you don't duplicate it.
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.
done
fa853d2
to
52989ee
Compare
Related to #5718 (comment)