Skip to content

Commit 3721537

Browse files
Update User.php
1 parent eaba5dd commit 3721537

File tree

1 file changed

+4
-0
lines changed

1 file changed

+4
-0
lines changed

src/models/User.php

+4
Original file line numberDiff line numberDiff line change
@@ -443,6 +443,10 @@ public function getRoleSubjectsArray($role)
443443
public function getRoleSlaves($roles1, $roles2, $subject_id = null)
444444
{
445445
$subjects = self::getRoleSubjectsArray($roles1);
446+
447+
if (empty($subjects)) {
448+
return [];
449+
}
446450

447451
if ($subject_id) {
448452
$subject_id = !is_array($subject_id) ? [$subject_id] : $subject_id;

0 commit comments

Comments
 (0)