From db6d296f055b164606521905930c1d1252a1d197 Mon Sep 17 00:00:00 2001 From: pikiou Date: Sun, 9 Jan 2022 04:49:07 +0100 Subject: [PATCH] Fix notification queries --- src/components/Notifications/index.tsx | 14 ++++++++++++-- src/server/gsheets/volunteers.ts | 2 +- 2 files changed, 13 insertions(+), 3 deletions(-) diff --git a/src/components/Notifications/index.tsx b/src/components/Notifications/index.tsx index b917387..bb381a8 100644 --- a/src/components/Notifications/index.tsx +++ b/src/components/Notifications/index.tsx @@ -115,8 +115,18 @@ const Notifications = ({ dispatch, jwt, volunteerNotifs }: Props): JSX.Element =
{participation === "peut-etre" ? (
- On te redemandera dans quelques temps. Si tu as des - questions + On te le reproposera dans quelques temps. +
+ Si tu as besoin d'infos, viens nous en parler sur le + serveur Discord ! Pour le rejoindre,{" "} + + clique ici{" "} + + .
) : null}
diff --git a/src/server/gsheets/volunteers.ts b/src/server/gsheets/volunteers.ts index 790939a..a5a0fbd 100644 --- a/src/server/gsheets/volunteers.ts +++ b/src/server/gsheets/volunteers.ts @@ -92,7 +92,7 @@ export const volunteerForgot = expressAccessor.set( export const volunteerNotifsSet = expressAccessor.set( async (list: Volunteer[], body: RequestBody, id: number) => { const requestedId = +body[0] - if (requestedId !== id) { + if (requestedId !== id && requestedId !== 0) { throw Error(`On ne peut acceder qu'à ses propres notifs`) } const notifChanges = body[1]