From 2d2ef384229ba39af6743cf32bbea011d3bdca71 Mon Sep 17 00:00:00 2001 From: Aaron van Geffen Date: Sun, 22 Dec 2024 15:45:44 +0100 Subject: [PATCH] MainNavBar: harden Registry access --- templates/MainNavBar.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/templates/MainNavBar.php b/templates/MainNavBar.php index 51ae4c1..7b7b5e4 100644 --- a/templates/MainNavBar.php +++ b/templates/MainNavBar.php @@ -33,7 +33,7 @@ class MainNavBar extends NavBar '; - if (Registry::get('user')->isLoggedIn()) + if (Registry::has('user') && Registry::get('user')->isLoggedIn()) { echo '