fix: [authKeycloakBehavior] Typo preventing roles to be saved

cli-modification-summary
Sami Mokaddem 2022-09-21 10:05:55 +02:00
parent 8d26be28a2
commit efe917c824
No known key found for this signature in database
GPG Key ID: 164C473F627A06FA
1 changed files with 1 additions and 1 deletions

View File

@ -444,7 +444,7 @@ class AuthKeycloakBehavior extends Behavior
$toRemove = array_diff($keycloakUserRoles, array_keys($userRoles)); $toRemove = array_diff($keycloakUserRoles, array_keys($userRoles));
$changed = false; $changed = false;
foreach ($toRemove as $k => $role) { foreach ($toRemove as $k => $role) {
if (substr($role, 0, strlen('Organisation:')) !== 'Organisation:' && substr($role, 0, strlen('Role:') !== 'Role:')) { if (substr($role, 0, strlen('Organisation:')) !== 'Organisation:' && substr($role, 0, strlen('Role:')) !== 'Role:') {
unset($toRemove[$k]); unset($toRemove[$k]);
} else { } else {
$toRemove[$k] = $assignedRolesParsed[$role]; $toRemove[$k] = $assignedRolesParsed[$role];