You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
thanks for the great work!
It seems, there's a logic error for the super_admin role creation.
If the super_admin is disabled it still creates the super admin role, whenever a new policy is generated.
In my case, I don't need the super admin role at all, so I deactivated it in the config file. Still the role is added every time I'm generating a policy.
The text was updated successfully, but these errors were encountered:
artjom
changed the title
super_admin role
super_admin role generation
Apr 25, 2024
hey,
thanks for the great work!
It seems, there's a logic error for the super_admin role creation.
If the super_admin is disabled it still creates the super admin role, whenever a new policy is generated.
protected static function giveSuperAdminPermission(string | array | Collection $permissions): void { if (! Utils::isSuperAdminDefinedViaGate()) { $superAdmin = static::createRole(); $superAdmin->givePermissionTo($permissions); app(PermissionRegistrar::class)->forgetCachedPermissions(); } }
In my case, I don't need the super admin role at all, so I deactivated it in the config file. Still the role is added every time I'm generating a policy.
The text was updated successfully, but these errors were encountered: