-
-
Notifications
You must be signed in to change notification settings - Fork 937
Fixing jest failure tests, adding test for registration denied. #6267
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
Conversation
| RegistrationDenied { | ||
| #[cfg_attr(feature = "ts-rs", ts(optional))] | ||
| reason: Option<String>, | ||
| }, |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This was incorrect, and I fixed it.
| /// A remote community sent an activity to us, but actually no local user follows the community | ||
| /// so the activity was rejected. | ||
| CommunityHasNoFollowers(String), | ||
| ResolveObjectFailed(String), |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Moved this to a standard LemmyError. Really UntranslatedError should only be for federation / internal errors. Anything that the API can potentially return should be a LemmyError
| new LemmyError( | ||
| "resolve_object_failed", | ||
| statusBadRequest, | ||
| 'Domain "lemmy-alpha" is not in allowlist', |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Here's an example of the internal error message being returned and checked.
We don't actually have to show this in lemmy-ui, but it might be good to console log it there anyway.
) * Return error details in HTTP response * separate error * make format of UntranslatedError match LemmyErrorType * Fixing jest failure tests, adding test for registration denied. (#6267) * Fixing jest failure tests, adding test for registration denied. * Fixing tests. --------- Co-authored-by: Dessalines <dessalines@users.noreply.github.com>
No description provided.