-
Notifications
You must be signed in to change notification settings - Fork 12
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
Bringing realm roles and permissions up to date on a fresh branch #156
Conversation
server/boards/queries.ts
Outdated
}[] | ||
| null | ||
> => { | ||
try { |
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.
No need to try/catch anymore in these. Just let the exception rip.
server/realms/routes.ts
Outdated
}); | ||
} catch (e) { | ||
error(e); | ||
res.status(500).json({ |
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.
Instead of doing this, you can directly throw a 500 error and it will be handled by the server:
boba-backend/server/realms/routes.ts
Line 486 in dde9b0c
throw new Internal500Error("failed to get realm ids"); |
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.
Left two comments on the new way we do things
Moving over changes from PR 126 to allow admin/owner role to view realm and board roles. Addresses most of BobaBoard/issues/issues/133
Also updates relevant Zod types.