Opened 8 years ago
Closed 8 years ago
#37389 closed defect (bug) (fixed)
Incorrect WP_Error usage in WP_Tax_Query
Reported by: | SergeyBiryukov | Owned by: | SergeyBiryukov |
---|---|---|---|
Milestone: | 4.6 | Priority: | normal |
Severity: | normal | Version: | 3.2 |
Component: | Taxonomy | Keywords: | |
Focuses: | Cc: |
Description
In WP_Tax_Query::clean_query()
and WP_Tax_Query::transform_query()
, strings are used as error codes:
$query = new WP_Error( 'Invalid taxonomy' ); ... $query = new WP_Error( 'Inexistent terms' );
Correct usage would be:
$query = new WP_Error( 'invalid_taxonomy', __( 'Invalid taxonomy.' ) ); ... $query = new WP_Error( 'inexistent_terms', __( 'Inexistent terms.' ) );
Introduced in [17686].
Change History (1)
Note: See
TracTickets for help on using
tickets.
In 38079: