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

Fix error decoding #169

Merged
merged 1 commit into from
Nov 28, 2023

Conversation

theolampert
Copy link
Contributor

@theolampert theolampert commented Nov 27, 2023

What kind of change does this PR introduce?

Fixes a small bug when decoding API errors in the GoTrue package.

What is the current behavior?

The current keyDecodingStrategy used by the GoTrue package already decodes from snake case to camel case, however coding keys were explicitly set, leading to an error message with missing information. I came across this when trying out Supabase for the first time and receiving an error about an unconfirmed email address, it was impossible to debug this without running a network proxy and inspecting the response.

What is the new behavior?

Removes codingKeys from GoTrueError.APIError as this is covered already by keyDecodingStrategy and was causing issues.

Copy link
Collaborator

@grdsdev grdsdev left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thank you @theolampert

@grdsdev grdsdev enabled auto-merge (squash) November 28, 2023 08:15
@grdsdev grdsdev merged commit 3adc23c into supabase:main Nov 28, 2023
2 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants