-
Notifications
You must be signed in to change notification settings - Fork 134
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
feat: stake and delegation transfer tools for L2 #786
Conversation
b53a0fd
to
18eb0a2
Compare
74cfbfa
to
fa0f97e
Compare
Codecov ReportPatch coverage:
Additional details and impacted files@@ Coverage Diff @@
## dev #786 +/- ##
==========================================
+ Coverage 93.53% 94.44% +0.91%
==========================================
Files 44 49 +5
Lines 2257 2429 +172
Branches 401 436 +35
==========================================
+ Hits 2111 2294 +183
+ Misses 146 135 -11
Flags with carried forward coverage won't be shown. Click here to find out more.
☔ View full report in Codecov by Sentry. |
f461fa3
to
3bce7f9
Compare
e5e0eff
to
ed02752
Compare
41419b2
to
4325579
Compare
4325579
to
83fffa3
Compare
…sion fee (OZ M-01 for #786)
…is received (OZ M-03)
…Z M-07) Signed-off-by: Tomás Migone <tomas@edgeandnode.com>
…o shares (OZ M-09)
require(_amount >= __minimumIndexerStake, "!minimumIndexerStake sent"); | ||
} | ||
// Ensure minimum stake | ||
indexerStake.tokensStaked = indexerStake.tokensStaked.sub(_amount); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think we could use indexerStake.release(_amount)
here but it's fine
tokensDelegatedCap | ||
); | ||
require( | ||
indexerStake.tokensUsed() <= indexerStake.tokensStaked.add(tokensDelegatedCapacity), |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thinking this might be replaced by getIndexerCapacity(_indexer) > 0
See GIP-0046: https://forum.thegraph.com/t/gip-0046-l2-migration-helpers/4023