diff --git a/src/pages/events/util.ts b/src/pages/events/util.ts index af0c2ec..3fc8b9b 100644 --- a/src/pages/events/util.ts +++ b/src/pages/events/util.ts @@ -30,7 +30,7 @@ export const useEventRights = (event?: EventModel) => { return { canEditEvent: isEventAdmin || isStex, - isPrivilegedUser: privilegedUsers.includes(user?.id), + isPrivilegedUser: user && privilegedUsers.includes(user?.id), } }