Skip to content

Commit

Permalink
Remove auth permission to view notification
Browse files Browse the repository at this point in the history
Remove auth permission to view notification
  • Loading branch information
DJensen94 committed Apr 9, 2024
1 parent 6c3c5ad commit 26667be
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 8 deletions.
2 changes: 1 addition & 1 deletion backend/src/api/app.ts
Original file line number Diff line number Diff line change
Expand Up @@ -451,7 +451,7 @@ authenticatedRoute.put(
handlerToExpress(users.registrationDenial)
);

authenticatedRoute.get(
app.get(
'/notifications',
handlerToExpress(notifications.list)
)
Expand Down
14 changes: 7 additions & 7 deletions backend/src/api/notifications.ts
Original file line number Diff line number Diff line change
Expand Up @@ -105,13 +105,13 @@ export const del = wrapHandler(async (event) => {
export const list = wrapHandler(async (event) => {
console.log('list function called with event: ', event);

if (!isGlobalWriteAdmin(event)) {
return {
//TODO: Should we return a 403?
statusCode: 200,
body: JSON.stringify([])
};
}
// if (!isGlobalWriteAdmin(event)) {
// return {
// //TODO: Should we return a 403?
// statusCode: 200,
// body: JSON.stringify([])
// };
// }
await connectToDatabase();
console.log('Database connected');

Expand Down

0 comments on commit 26667be

Please sign in to comment.