public function is_member_of($table, $uid)
	{
		if (!in_array($table, array('applicants', 'members', 'managers', 'invitees')))
		{
			return false;
		}

		if (!is_numeric($uid))
		{
			$uid = User::oneByUsername($uid)->get('id');
		}

		return in_array($uid, $this->get($table));
	}
public function is_member_of($table, $uid)
	{
		if (!in_array($table, array('applicants', 'members', 'managers', 'invitees')))
		{
			return false;
		}

		if (!is_numeric($uid))
		{
			$uid = User::oneByUsername($uid)->get('id');
		}

		return in_array($uid, $this->get($table));
	}
public function is_member_of ( $ table , $ uid ) { if ( ! in_array ( $ table , array ( 'applicants' , 'members' , 'managers' , 'invitees' ) ) ) { return false ; } if ( ! is_numeric ( $ uid ) ) { $ uid = User :: oneByUsername ( $ uid ) -> get ( 'id' ) ; } return in_array ( $ uid , $ this -> get ( $ table ) ) ; }
Check if the user is a member of a given table

@param   string   $table  Table to check
@param   integer  $uid    User ID
@return  boolean
Check if the user is a member of a given table