Update error message for other errors during account linking - #2510
Merged
Conversation
- add Account linking error prefix
|
The latest updates on your projects. Learn more about Vercel for GitHub.
|
lwin-kyaw
previously approved these changes
Jun 2, 2026
chaitanyapotti
approved these changes
Jun 2, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Jira Link
Description
Update error message for other errors during account linking
Account linking errorprependHow has this been tested?
Screenshots (if appropriate)
Before - when type of error is not
AccountLinkingErrorwe plainly show the error messageAfter
If error is Web3Auth error. we prepend it with `[CODE] Account linking error: {message}

For other errors (no error code). we just prepend it `Account linking error:

Note: we don't show UI for unlinking so we only have
Account linking error:prependTypes of changes
Checklist
Note
Low Risk
Small change to error string formatting in account linking with no auth or API behavior changes; only user-visible error text differs for some error types.
Overview
formatAccountLinkingErrorMessagenow standardizes user-facing copy for non–AccountLinkingErrorfailures during account linking.Other
Web3AuthErrorinstances (notAccountLinkingError) are formatted as[code] Account linking error: {message}, so error codes still appear when the underlying failure is a Web3Auth error type. PlainErrorvalues are prefixed withAccount linking error:instead of showing only the raw message.AccountLinkingErrorand JSON/fallback paths are unchanged.Tests were updated to expect the new generic
Errorstring.Reviewed by Cursor Bugbot for commit 657d6b8. Bugbot is set up for automated code reviews on this repo. Configure here.