-
Notifications
You must be signed in to change notification settings - Fork 242
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
[DEMO] how we could replace specific token operations with the generic 2771 call proxy #2035
base: dev
Are you sure you want to change the base?
Conversation
… with increaseAllowance
Changelog ReminderReminder to update the CHANGELOG.md for any of the modified packages in this PR.
|
Codecov ReportAttention: Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## supertokenlib-iteration #2035 +/- ##
===========================================================
- Coverage 88.00% 87.99% -0.02%
===========================================================
Files 108 108
Lines 6768 6779 +11
Branches 974 974
===========================================================
+ Hits 5956 5965 +9
- Misses 810 812 +2
Partials 2 2
Flags with carried forward coverage won't be shown. Click here to find out more. ☔ View full report in Codecov by Sentry. |
note: |
Needed changes:
IRelayRecipient
, trusting the DMZForwardermsg.sender
with_msgSender()
(which uses the 2771-encoded sender if present)Here only
SuperToken.increaseAllowance()
was changed that way, with a new test case using it.In order to do this, we'd need to
_msgSender()
in all SuperToken methodsAs long as there's SuperTokens not updated to this logic, we can't easily remove the then legacy operations types from batch call.
However we could remove the code from SuperToken if we conditionally re-map legacy operations in
Superfluid.sol
to use 2771Forwarder if the target token contract supports it.