Skip to content
This repository was archived by the owner on Sep 19, 2022. It is now read-only.

Commit 12f98a6

Browse files
vyskocilpavelpajavyskocil
authored andcommitted
Renamed isUserOnFacility to getUsersGroupsOnFacility
1 parent 6e6f431 commit 12f98a6

File tree

4 files changed

+4
-4
lines changed

4 files changed

+4
-4
lines changed

lib/Adapter.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -74,7 +74,7 @@ public abstract function getUserAttributes($user, $attrNames);
7474
* @param int $userId
7575
* @return sspmod_perun_model_Group[] from vo which are assigned to all facilities with spEntityId for this userId
7676
*/
77-
public abstract function isUserOnFacility($spEntityId, $userId);
77+
public abstract function getUsersGroupsOnFacility($spEntityId, $userId);
7878

7979
/**
8080
* @param sspmod_perun_model_HasId[] $entities

lib/AdapterLdap.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -140,7 +140,7 @@ public function getUserAttributes($user, $attrNames)
140140
}
141141

142142

143-
public function isUserOnFacility($spEntityId, $userId)
143+
public function getUsersGroupsOnFacility($spEntityId, $userId)
144144
{
145145
$resources = sspmod_perun_LdapConnector::searchForEntities($this->ldapBase,
146146
"(&(objectClass=perunResource)(entityID=$spEntityId))",

lib/AdapterRpc.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -154,7 +154,7 @@ public function getUserAttributes($user, $attrNames)
154154
}
155155

156156

157-
public function isUserOnFacility($spEntityId, $userId)
157+
public function getUsersGroupsOnFacility($spEntityId, $userId)
158158
{
159159
$facilities = sspmod_perun_RpcConnector::get('facilitiesManager', 'getFacilitiesByAttribute', array(
160160
'attributeName' => 'urn:perun:facility:attribute-def:def:entityID',

lib/Auth/Process/PerunIdentity.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -137,7 +137,7 @@ public function process(&$request)
137137
$this->register($request, $this->registerUrl, $this->callbackParamName, $vo, $spGroups, $this->interface);
138138
}
139139

140-
$groups = $this->adapter->isUserOnFacility($spEntityId,$user->getId());
140+
$groups = $this->adapter->getUsersGroupsOnFacility($spEntityId,$user->getId());
141141

142142
if (empty($groups)) {
143143
SimpleSAML\Logger::warning('Perun user with identity/ies: '. implode(',', $uids) .' is not member of any assigned group for resource (' . $spEntityId . ')');

0 commit comments

Comments
 (0)