Skip to content
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

Fix paymaster when using rainbowkit connector #17

Merged
merged 4 commits into from
Sep 19, 2024
Merged

Fix paymaster when using rainbowkit connector #17

merged 4 commits into from
Sep 19, 2024

Conversation

coffeexcoin
Copy link
Collaborator

No description provided.

@@ -125,15 +126,36 @@ function abstractWalletConnector(
transport,
});

const paymasterParams = params[0].eip712Meta.paymasterParams
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'll take a look into this PR a bit more closely - I have a feeling there might be an existing formatter in the zksync viem package than can help with this

@cygaar cygaar merged commit e1a2f45 into main Sep 19, 2024
1 check passed
@cygaar cygaar deleted the fix-paymaster branch September 19, 2024 02:37
// Formatter: https://github.com/wevm/viem/blob/main/src/zksync/formatters.ts#L114
if (transaction.eip712Meta) {
transaction.paymaster =
transaction.eip712Meta.paymasterParams.paymaster;
Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Is it possible to have eip712Meta but no paymaster params? Might need a null check here.

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

true

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants