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

Localized errors #13

Open
foxfriends opened this issue Nov 14, 2020 · 0 comments
Open

Localized errors #13

foxfriends opened this issue Nov 14, 2020 · 0 comments
Labels
backend Requires updating the backend (Rust) code frontend Requires updating the frontend (JS/Svelte) code

Comments

@foxfriends
Copy link
Owner

foxfriends commented Nov 14, 2020

Errors sent from the server look like { code: string, message: string }. Currently when an error is received, the message is toasted to the player. We should instead use the code to look up a localization, and include in the error message any parameters required to fill in the blanks of that localized error message. The existing data property of the response could be used for this purpose ({ error: { code: string, message: string }, data: { ... } })

@foxfriends foxfriends added backend Requires updating the backend (Rust) code frontend Requires updating the frontend (JS/Svelte) code labels Nov 21, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
backend Requires updating the backend (Rust) code frontend Requires updating the frontend (JS/Svelte) code
Projects
None yet
Development

No branches or pull requests

1 participant