Making WordPress.org


Ignore:
Timestamp:
07/28/2017 07:48:04 PM (6 years ago)
Author:
Otto42
Message:

Plugin Directory: rm errant in_array call, introduced in [5719]. Eliminates error message on plugin pages

File:
1 edited

Legend:

Unmodified
Added
Removed
  • sites/trunk/wordpress.org/public_html/wp-content/plugins/plugin-directory/class-plugin-directory.php

    r5719 r5725  
    807807     */
    808808    public function filter_found_posts( $found_posts, $wp_query ) {
    809         if ( isset( $wp_query->query['browse'] ) && in_array( 'plugin', $wp_query->query_vars['post_type'] ) ) {
     809        if ( isset( $wp_query->query['browse'] ) && $wp_query->query_vars['post_type'] == 'plugin' ) {
    810810            return min( $found_posts, 99 * $wp_query->query_vars['posts_per_page'] ); // 99 pages
    811811        }
Note: See TracChangeset for help on using the changeset viewer.