/**
  * Check if user is allowed to see this action
  *
  * @return bool
  */
 protected function allowedUserForInvitationNewAndCreate()
 {
     if (empty($this->settings['invitation']['allowedUserGroups'])) {
         return true;
     }
     $allowedUsergroupUids = GeneralUtility::trimExplode(',', $this->settings['invitation']['allowedUserGroups'], true);
     $currentUsergroupUids = UserUtility::getCurrentUsergroupUids();
     // compare allowedUsergroups with currentUsergroups
     if (count(array_intersect($allowedUsergroupUids, $currentUsergroupUids))) {
         return true;
     }
     // current user is not allowed
     $this->addFlashMessage(LocalizationUtility::translateByState(Log::STATUS_INVITATIONRESTRICTEDPAGE), '', FlashMessage::ERROR);
     $this->forward('status');
     return false;
 }