-
Notifications
You must be signed in to change notification settings - Fork 72
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
Add relayer functionality to fastauth #162
Conversation
MaximusHaximus
commented
Apr 28, 2023
•
edited
Loading
edited
- Updates recovery service API calls to match advanced account API
- Implements near-social LAK-only functionality for fastauth accounts
- Adds relayer awareness to fastauth implementation
- Bumps NAJ to 2.1.3
- Bumps wallet-selector to latest versions
The latest updates on your projects. Learn more about Vercel for Git ↗︎
|
try { | ||
if ( | ||
!accountCreationData.limitedAccessKey || | ||
!accountCreationData.isCreated |
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 might be missing something here, but shouldn't this be:
!accountCreationData.isCreated | |
accountCreationData.isCreated |
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.
This case is a bit counter-intuitive -- after creating the account via recovery service, we redirect to the app after setting a flag indicating that the account was created successfully -- so this is correct, if the account wasn't created we can't yet fire the signIn() logic here
isRecovery ? "Recovering account..." : "Creating account..." | ||
); | ||
|
||
// TODO: Call MPC Service with accountId, publicKey, and oauthToken to create account |
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.
Isn't this TODO done?
}; | ||
|
||
await fetch( | ||
`${MPC_RECOVERY_URL}/${isRecovery ? "add_key" : "new_account"}`, |
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 don't think add_key
supports CreateAccountOptions
. Do you need us to add it?