WordPress.org

Make WordPress Core


Ignore:
Timestamp:
04/14/2017 08:53:11 AM (3 years ago)
Author:
swissspidy
Message:

REST API: Allow fetching multiple terms at once via the slug parameter.

This matches a similar change previously made for posts (#38579) and an upcoming change for users (#40213).

Props wonderboymusic, MatheusGimenez, curdin.
Fixes #40027.

Merges [40376] to the 4.7 branch.

Location:
branches/4.7
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • branches/4.7

  • branches/4.7/src/wp-includes/rest-api/endpoints/class-wp-rest-terms-controller.php

    r39957 r40427  
    980980        $query_params['slug'] = array(
    981981            'description'       => __( 'Limit result set to terms with a specific slug.' ),
    982             'type'              => 'string',
     982            'type'              => 'array',
     983            'items'             => array(
     984                'type'          => 'string'
     985            ),
    983986        );
    984987
Note: See TracChangeset for help on using the changeset viewer.