Beispiel #1
0
 /**
  * Verify Group membership
  *
  * @param	mixed	group identifier to check for membership
  * @param	string	group driver id or null to check all
  * @param	array	user identifier to check in form array(driver_id, user_id)
  * @return	bool
  */
 public function member($group, $driver = null, $user = null)
 {
     $user = $user ?: $this->get_user_id();
     if ($driver === null) {
         foreach (\Auth::group(true) as $group) {
             if ($group->group($group, $user)) {
                 return true;
             }
         }
         return false;
     }
     return \Auth::group($driver)->member($group, $user);
 }