From 3dc8b0ddebe8069e030ae566c941a17a6701d174 Mon Sep 17 00:00:00 2001 From: Danny Miller Date: Wed, 19 Jun 2024 13:09:08 -0400 Subject: [PATCH] disallow reporting if not logged in and not a guest user --- components/level/info/levelDropdown.tsx | 3 +++ 1 file changed, 3 insertions(+) diff --git a/components/level/info/levelDropdown.tsx b/components/level/info/levelDropdown.tsx index 2188ce5b7..9ca36149f 100644 --- a/components/level/info/levelDropdown.tsx +++ b/components/level/info/levelDropdown.tsx @@ -10,6 +10,7 @@ import { ReportType } from '@root/constants/ReportType'; import { AppContext } from '@root/contexts/appContext'; import { PageContext } from '@root/contexts/pageContext'; import isCurator from '@root/helpers/isCurator'; +import isGuest from '@root/helpers/isGuest'; import Level from '@root/models/db/level'; import classNames from 'classnames'; import Link from 'next/link'; @@ -330,6 +331,7 @@ export default function LevelDropdown({ level }: LevelDropdownProps) { } } + { user && !isGuest(user) && {({ active }) => (
)} + }