public function WebformAccessGroup::removeAdminId in Webform 6.x
Same name and namespace in other branches
- 8.5 modules/webform_access/src/Entity/WebformAccessGroup.php \Drupal\webform_access\Entity\WebformAccessGroup::removeAdminId()
Remove admin user id to webform access group.
Parameters
int $uid: A user id.
Return value
$this
Overrides WebformAccessGroupInterface::removeAdminId
File
- modules/
webform_access/ src/ Entity/ WebformAccessGroup.php, line 227
Class
- WebformAccessGroup
- Defines the webform access group entity.
Namespace
Drupal\webform_access\EntityCode
public function removeAdminId($uid) {
foreach ($this->adminIds as $index => $adminId) {
if ($adminId === $uid) {
unset($this->adminIds[$index]);
}
}
$this->adminIds = array_values($this->adminIds);
return $this;
}