src/Post.php
public function in( $key = '', $data = '', $default = false ) {
		if ( is_array( $data ) ) {
			return ( in_array( $key, $data ) ) ? $key : $default;
		}
		if ( isset( $this->{$data} ) ) {
			return ( in_array( $key, $this->{$data} ) ) ? $key : $default;
		}
		return $default;
	}
public function in( $key = '', $data = '', $default = false ) {
		if ( is_array( $data ) ) {
			return ( in_array( $key, $data ) ) ? $key : $default;
		}
		if ( isset( $this->{$data} ) ) {
			return ( in_array( $key, $this->{$data} ) ) ? $key : $default;
		}
		return $default;
	}
public function in ( $ key = '' , $ data = '' , $ default = false ) { if ( is_array ( $ data ) ) { return ( in_array ( $ key , $ data ) ) ? $ key : $ default ; } if ( isset ( $ this -> { $ data } ) ) { return ( in_array ( $ key , $ this -> { $ data } ) ) ? $ key : $ default ; } return $ default ; }
Checks if given key is in array

@uses \in_array()
@uses \VS_WP_Post

@example in('somekey','post_category','no') post_category will be taken from post data.
@example in('somekey',array('somekey' => 'somekey'), will be used the given array.

@param string $key
@param string $data
@param bool   $default

@return bool|string
Checks if given key is in array