From 88f546827298736114a192a2144b7c4168548e0b Mon Sep 17 00:00:00 2001 From: Valentin Sampl Date: Tue, 31 Oct 2023 15:54:22 +0100 Subject: [PATCH] Add admin order note user check --- src/Controller/AdminOrderController.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/Controller/AdminOrderController.php b/src/Controller/AdminOrderController.php index a81e2fee..89f8c57b 100644 --- a/src/Controller/AdminOrderController.php +++ b/src/Controller/AdminOrderController.php @@ -329,7 +329,7 @@ public function detailAction( $quantity = null; // get avatar - $user = User::getById($note->getUser()); + $user = $note->getUser() ? User::getById($note->getUser()) : null; $avatar = $user ? sprintf('/admin/user/get-image?id=%d', $user->getId()) : null; // group events