From 1a658e67ddab70ad3b731af5e85ee0d16f318f4a Mon Sep 17 00:00:00 2001
From: Jan-Hendrik Willms <tleilax+github@gmail.com>
Date: Tue, 10 May 2022 08:57:20 +0200
Subject: [PATCH] fix regression from 0d95625c2ab0eabe98e724ab79be0087093cc35b,
 re #957

---
 lib/phplib/Seminar_Perm.class.php | 8 ++------
 1 file changed, 2 insertions(+), 6 deletions(-)

diff --git a/lib/phplib/Seminar_Perm.class.php b/lib/phplib/Seminar_Perm.class.php
index c27d2ad5bb9..4e8c0f82300 100644
--- a/lib/phplib/Seminar_Perm.class.php
+++ b/lib/phplib/Seminar_Perm.class.php
@@ -219,12 +219,8 @@ class Seminar_Perm
     {
         $pageperm = $this->permissions[$perm] ?? 0;
         $userperm = $this->permissions[$this->get_studip_perm($range_id, $user_id)] ?? 0;
-        if ($userperm) {
-            return $pageperm <= $userperm;
-        } else {
-            //The user has no permissions at all.
-            return false;
-        }
+
+        return $pageperm <= $userperm;
     }
 
     /**
-- 
GitLab