Skip to content

FAILED_TO_UNLINK_LAST_ACCOUNT Localization Fails in AuthUIProvider #221

@e-renna

Description

@e-renna

When attempting to localize the error message for FAILED_TO_UNLINK_LAST_ACCOUNT by passing a custom translation string to AuthUIProvider's localization prop, the change has no effect. The default message, "You can't unlink your last account," is consistently displayed instead of the custom string.

I have confirmed that localization for other error codes, such as PASSWORD_COMPROMISED (from the HaveIBeenPwned integration), functions as expected when passed via the localization prop.

I have not extensively tested other error codes from Base Error Codes but have observed the failure specifically with FAILED_TO_UNLINK_LAST_ACCOUNT. It is possible that other codes (https://github.com/daveyplate/better-auth-ui/blob/main/src/localization/base-error-codes.ts) have the same issue.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions