We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent e873775 commit 81da6efCopy full SHA for 81da6ef
peerprep-fe/src/components/navbar/Navbar.tsx
@@ -38,9 +38,14 @@ export default function Navbar() {
38
<Link href="/" className="text-gray-300 hover:text-white">
39
Questions
40
</Link>
41
- <Link href="/match" className="text-gray-300 hover:text-white">
42
- Match
43
- </Link>
+ {/* Admin users should be able to add questions instead of match */}
+ {user?.isAdmin ?
+ <Link href="/match" className="text-gray-300 hover:text-white">
44
+ Match
45
+ </Link> :
46
+ <Link href="/add-question" className="text-gray-300 hover:text-white">
47
+ Add Question
48
+ </Link>}
49
{isAuth ? (
50
<DropdownMenu>
51
<DropdownMenuTrigger asChild>
0 commit comments