From c3e4c04b85a72c0895d871a3a0f2831d45d52202 Mon Sep 17 00:00:00 2001 From: dengxit Date: Sat, 27 Mar 2021 19:28:29 +0800 Subject: [PATCH] fix: return true when the role does not have permissions but the user has direct permissions . close #291 --- app/Laravue/Models/User.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/app/Laravue/Models/User.php b/app/Laravue/Models/User.php index f8ae7e4ff..f99e4efd8 100644 --- a/app/Laravue/Models/User.php +++ b/app/Laravue/Models/User.php @@ -83,7 +83,7 @@ public function hasPermission($permission): bool return true; } } - return false; + return $this->hasDirectPermission($permission); } /**