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

PIP36: use call over transfer in mrc20 #5

Merged
merged 17 commits into from
Oct 14, 2024
Merged

Conversation

DhairyaSethi
Copy link
Contributor

@DhairyaSethi DhairyaSethi commented May 6, 2024

Rationale: https://github.com/maticnetwork/Polygon-Improvement-Proposals/blob/main/PIPs/PIP-36.md

This PR updated transfer to call during Plasma Deposits on MRC20 (ie matic token on Polygon PoS). The updates:

  • Fix pragma of token to 0.5.17 (all contracts are currently compiled to 0.5.17, this just removed the floating pragma specifically here)
  • MRC20.deposit: replace transfer with call, and bubble up any reverts, fixed gas of 5000 is passed.
  • MRC20.transfer is intentionally kept to re-use transfer, for external callers to support sending tokens to Gnosis Safe or SCW's, please use Access Lists.
  • Tests for the above.

@simonDos simonDos self-requested a review May 6, 2024 17:23
@DhairyaSethi DhairyaSethi changed the base branch from main to dev May 7, 2024 09:35
Copy link
Contributor

@simonDos simonDos left a comment

Choose a reason for hiding this comment

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

Approved from my side, internal security review pending.

@DhairyaSethi DhairyaSethi requested a review from dev1644 May 9, 2024 02:29
Copy link

sonarcloud bot commented May 20, 2024

Quality Gate Passed Quality Gate passed

Issues
0 New issues
0 Accepted issues

Measures
0 Security Hotspots
No data about Coverage
0.0% Duplication on New Code

See analysis details on SonarCloud

Copy link

sonarcloud bot commented Jul 22, 2024

@simonDos
Copy link
Contributor

added MATIC > POL rename

Copy link

sonarcloud bot commented Aug 27, 2024

@simonDos simonDos merged commit 6ce9247 into dev Oct 14, 2024
1 check passed
Copy link

sonarcloud bot commented Oct 14, 2024

@simonDos simonDos deleted the feat/use-call-over-transfer branch October 14, 2024 15:13
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.

3 participants