Skip to content
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

API Errors not localized #1285

Open
nmago opened this issue Apr 22, 2024 · 2 comments
Open

API Errors not localized #1285

nmago opened this issue Apr 22, 2024 · 2 comments
Assignees
Labels
good first issue Good for newcomers

Comments

@nmago
Copy link

nmago commented Apr 22, 2024

Hello, guys!

Thank you for putting in such effort into the template codebase; the thing seems amazing.

I have a localization-related question. Upon my initial examination of the codebase, I noticed that API errors aren't localized and are always returned in plain English.

For example, in the file pages/auth/forgot-password.tsx:

if (!response.ok) {
  toast.error(json.error.message);
  return;
}

toast.success(t('password-reset-link-sent'));

While the success message is being translated, the API error is being passed as is.

Is this intentional or left for the future? Maybe I'm missing something?

@ukrocks007 ukrocks007 added the good first issue Good for newcomers label Apr 25, 2024
@Musyonchez
Copy link
Contributor

Can I get assigned to this.

@deepakprabhakara
Copy link
Member

Thanks @Musyonchez, assigned the issue to you.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
good first issue Good for newcomers
Projects
None yet
Development

No branches or pull requests

4 participants