/** * @return bool */ public function canEdit() { $userId = $this->getUser()->getId(); // admin is always able to edit\remove comments if (Loader::includeModule("tasks") && (\CTasksTools::isAdmin($userId) || \CTasksTools::isPortalB24Admin($userId))) { return true; } return false; }