-
Notifications
You must be signed in to change notification settings - Fork 11.2k
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
Wallet validator unstaking1 #7403
Conversation
The latest updates on your projects. Learn more about Vercel for Git ↗︎
1 Ignored Deployment
|
4418bae
to
520e272
Compare
|
bc98a86
to
9beb49c
Compare
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.
Some small nits but overall LGTM
validatorAddress: SuiAddress; | ||
} | ||
|
||
export function useStakeTokenMutation() { |
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.
A couple things with this:
- I'd actually be okay if this was just defined inline and not in a separate file.
- This file is named
useStakingMutation
but that hook isn't actually exposed. Maybe rename to something likestakingHooks
?
if (unstake) return; | ||
const response = await dispatch( | ||
stakeTokens({ | ||
let response; |
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.
Not a blocking concern, but I think this could be done a little cleaner with onCompleted
handlers in the mutation. Don't bother changing now, we can improve this later.
a8ad5a8
to
670bf63
Compare
670bf63
to
5ab752d
Compare
I keep getting this error on devnet
Error: Error in getValidators: Error: RPC Error: The response returned from RPC server does not match the TypeScript definition. This is likely because the SDK version is not compatible with the RPC server. Please update your SDK version to the latest. ...
but works fine locally .Screen.Recording.2023-01-14.at.9.16.24.AM.mov