Skip to content

Ankit/add buy voucher with permit #8

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

Open
wants to merge 5 commits into
base: main
Choose a base branch
from

Conversation

ankitboghra
Copy link
Member

No description provided.

@ankitboghra ankitboghra requested a review from Copilot May 19, 2025 08:06
Copy link

@Copilot Copilot AI left a comment

Choose a reason for hiding this comment

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

Pull Request Overview

This PR introduces a new method to delegate amounts using a permit, along with a helper method to generate the permit signature data.

  • Added delegateAmountPOLwithPermit in validator_share.ts, which internally calls buyVoucherWithPermit.
  • Added getPermitData in matic_token.ts to generate permit signature data and updated import dependencies for TYPE_AMOUNT and Converter.

Reviewed Changes

Copilot reviewed 2 out of 3 changed files in this pull request and generated 1 comment.

File Description
src/contracts/validator_share.ts Added delegateAmountPOLwithPermit to handle delegation with permit for POL tokens.
src/contracts/matic_token.ts Added getPermitData to generate permit data and updated imports to support new types and utilities.
Files not reviewed (1)
  • package.json: Language not supported

spender: string
): Promise<{ v: number; r: string; s: string; deadline: number }> {
debugger
Copy link
Preview

Copilot AI May 19, 2025

Choose a reason for hiding this comment

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

Remove the 'debugger' statement to avoid unintended breakpoints in production code.

Suggested change
debugger

Copilot uses AI. Check for mistakes.

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