Code Duplication    Length = 3-3 lines in 3 locations

json-endpoints/class.wpcom-json-api-list-posts-endpoint.php 1 location

@@ 223-225 (lines=3) @@
220
		 * use it there.
221
		 */
222
		$column_whitelist = array( 'post_modified_gmt' );
223
		if ( isset( $args['column'] ) && in_array( $args['column'], $column_whitelist ) ) {
224
			$query['column'] = $args['column'];
225
		}
226
227
		$wp_query = new WP_Query( $query );
228
		if ( $this->date_range ) {

json-endpoints/class.wpcom-json-api-list-posts-v1-1-endpoint.php 1 location

@@ 261-263 (lines=3) @@
258
		 * use it there.
259
		 */
260
		$column_whitelist = array( 'post_modified_gmt' );
261
		if ( isset( $args['column'] ) && in_array( $args['column'], $column_whitelist ) ) {
262
			$query['column'] = $args['column'];
263
		}
264
265
		$this->performed_query = $query;
266
		add_filter( 'posts_orderby', array( $this, 'handle_orderby_for_page_handle' ) );

json-endpoints/class.wpcom-json-api-list-posts-v1-2-endpoint.php 1 location

@@ 259-261 (lines=3) @@
256
		 * use it there.
257
		 */
258
		$column_whitelist = array( 'post_modified_gmt' );
259
		if ( isset( $args['column'] ) && in_array( $args['column'], $column_whitelist ) ) {
260
			$query['column'] = $args['column'];
261
		}
262
263
		$this->performed_query = $query;
264
		add_filter( 'posts_orderby', array( $this, 'handle_orderby_for_page_handle' ) );