Making WordPress.org

Changeset 4452


Ignore:
Timestamp:
11/30/2016 10:27:58 PM (8 years ago)
Author:
tellyworth
Message:

Plugin directory search: reduce slug_ngram weighting because it's already high.

See #1692

File:
1 edited

Legend:

Unmodified
Added
Removed
  • sites/trunk/wordpress.org/public_html/wp-content/plugins/plugin-directory/libs/site-search/jetpack-search.php

    r4451 r4452  
    286286        $locale = get_locale();
    287287        if ( $locale && $locale !== 'en' && $locale !== 'en_US' ) {
    288             $es_wp_query_args['query_fields'] = array( "title_{$locale}^4", 'title_en^0.5', "content_{$locale}", 'content_en^0.5', "excerpt_{$locale}", 'excerpt_en', 'author', 'tag', 'category', 'slug_ngram^4', 'contributors' );
     288            $es_wp_query_args['query_fields'] = array( "title_{$locale}^4", 'title_en^0.5', "content_{$locale}", 'content_en^0.5', "excerpt_{$locale}", 'excerpt_en', 'author', 'tag', 'category', 'slug_ngram^0.25', 'slug', 'contributors' );
    289289        } else {
    290             $es_wp_query_args['query_fields'] = array( 'title_en^4', 'content_en', 'excerpt_en', 'author', 'tag', 'category', 'slug_ngram^4', 'contributors' );
     290            $es_wp_query_args['query_fields'] = array( 'title_en^4', 'content_en', 'excerpt_en', 'author', 'tag', 'category', 'slug_ngram^0.25', 'slug', 'contributors' );
    291291        }
    292292
Note: See TracChangeset for help on using the changeset viewer.