Making WordPress.org

Changeset 9160


Ignore:
Timestamp:
10/03/2019 05:44:13 AM (6 years ago)
Author:
tellyworth
Message:

Plugin directory: disable Jetpack plugin search module.

It was overriding our custom search code.

File:
1 edited

Legend:

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

    r9094 r9160  
    6868        // Allow post_modified not to be modified when we don't specifically bump it.
    6969        add_filter( 'wp_insert_post_data', array( $this, 'filter_wp_insert_post_data' ), 10, 2 );
     70
     71        add_filter( 'jetpack_active_modules', function( $modules ) {
     72            if ( $i = array_search( 'search', $modules ) )
     73                unset( $modules[$i] );
     74            return $modules;
     75        } );
    7076
    7177        // Work around caching issues
Note: See TracChangeset for help on using the changeset viewer.