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: handle unknown errcode #132

Merged
merged 4 commits into from
Mar 22, 2023
Merged

fix: handle unknown errcode #132

merged 4 commits into from
Mar 22, 2023

Conversation

sko00o
Copy link
Contributor

@sko00o sko00o commented May 7, 2022

Copy link
Owner

@doujiang24 doujiang24 left a comment

Choose a reason for hiding this comment

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

Thanks, please also fix the similar Errors[errcode] places.

Comment on lines 171 to 175
err = Errors[errcode]
if not err then
-- fallback any unknown errcode to UNKNOWN_SERVER_ERROR
err = Errors[-1]
end
Copy link
Owner

Choose a reason for hiding this comment

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

Suggested change
err = Errors[errcode]
if not err then
-- fallback any unknown errcode to UNKNOWN_SERVER_ERROR
err = Errors[-1]
end
err = Errors[errcode] or Errors[-1]

this is better.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Done.

@sko00o
Copy link
Contributor Author

sko00o commented May 9, 2022

Thanks, please also fix the similar Errors[errcode] places.

Alright, wait a sec.

local variable

Co-authored-by: doujiang <[email protected]>
@doujiang24 doujiang24 merged commit 860cfee into doujiang24:master Mar 22, 2023
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