24 $this->controller->addError(
'Wrong instance');
29 $target = (int)(
$params[
'userId'] ??
null);
32 $this->controller->addError(static::class,
'Wrong target');
37 if ($item->getId() <= 0)
39 $this->controller->addError(static::class,
'Group not found');
44 if (!$this->getAccessManager($item, $target, $this->user->getUserId())->canDeleteIncomingRequest())
46 $this->controller->addError(static::class,
'Access denied by permissions');