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

[4337] Modify the init function type in the Safe4337Pack to include paymentReceiver, payment, and paymentToken #1060

Open
DaniSomoza opened this issue Nov 25, 2024 · 0 comments

Comments

@DaniSomoza
Copy link
Contributor

Context / issue

Currently, the paymentReceiver, payment, and paymentToken properties are set with default values in the Safe4337Pack

see the default values in the Safe4337Pack.ts file:

      protocolKit = await Safe.init({
        provider,
        signer,
        predictedSafe: {
          safeDeploymentConfig: {
            safeVersion,
            saltNonce: options.saltNonce || undefined
          },
          safeAccountConfig: {
            owners: options.owners,
            threshold: options.threshold,
            to: deploymentTo,
            data: deploymentData,
            fallbackHandler: safe4337ModuleAddress,
            paymentToken: zeroAddress,
            payment: 0,
            paymentReceiver: zeroAddress
          }
        }
      })

We can make these properties accessible via the options parameter in the init function

This functionality is already available in the Protocol Kit, but not in the Relay Kit.

Proposed solution

Modify the init function type in the Safe4337Pack to include paymentReceiver, payment, and paymentToken in the options parameter.

@DaniSomoza DaniSomoza changed the title [4337] [4337] Modify the init function type in the Safe4337Pack to include paymentReceiver, payment, and paymentToken Nov 25, 2024
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

No branches or pull requests

1 participant