| @@ 248-252 (lines=5) @@ | ||
| 245 | if ($config->getAppValue('core', 'shareapi_exclude_groups', 'no') === 'yes') { |
|
| 246 | $groupsList = $config->getAppValue('core', 'shareapi_exclude_groups_list', ''); |
|
| 247 | $excludedGroups = json_decode($groupsList); |
|
| 248 | if (is_null($excludedGroups)) { |
|
| 249 | $excludedGroups = explode(',', $groupsList); |
|
| 250 | $newValue = json_encode($excludedGroups); |
|
| 251 | $config->setAppValue('core', 'shareapi_exclude_groups_list', $newValue); |
|
| 252 | } |
|
| 253 | $usersGroups = $groupManager->getUserGroupIds($user); |
|
| 254 | if (!empty($usersGroups)) { |
|
| 255 | $remainingGroups = array_diff($usersGroups, $excludedGroups); |
|
| @@ 1160-1164 (lines=5) @@ | ||
| 1157 | if ($this->config->getAppValue('core', 'shareapi_exclude_groups', 'no') === 'yes') { |
|
| 1158 | $groupsList = $this->config->getAppValue('core', 'shareapi_exclude_groups_list', ''); |
|
| 1159 | $excludedGroups = json_decode($groupsList); |
|
| 1160 | if (is_null($excludedGroups)) { |
|
| 1161 | $excludedGroups = explode(',', $groupsList); |
|
| 1162 | $newValue = json_encode($excludedGroups); |
|
| 1163 | $this->config->setAppValue('core', 'shareapi_exclude_groups_list', $newValue); |
|
| 1164 | } |
|
| 1165 | $user = $this->userManager->get($userId); |
|
| 1166 | $usersGroups = $this->groupManager->getUserGroupIds($user); |
|
| 1167 | if (!empty($usersGroups)) { |
|