mirror of
https://github.com/gosticks/wordpress-develop.git
synced 2026-03-24 23:34:30 +00:00
Remove the Featured Content term filters when running Unit Tests. Set the return value of wp_get_object_terms() to a var before passing to array_shift() in test_get_object_terms_types(), which expects a var to be passed by reference.
See #25282. git-svn-id: https://develop.svn.wordpress.org/trunk@26187 602fd350-edb4-49c9-b593-d223f7449a82
This commit is contained in:
@@ -381,4 +381,9 @@ function _cleanup_query_vars() {
|
||||
if ( ! empty( $t->query_var ) )
|
||||
$GLOBALS['wp']->add_query_var( $t->query_var );
|
||||
}
|
||||
}
|
||||
|
||||
function _clean_term_filters() {
|
||||
remove_filter( 'get_terms', array( 'Featured_Content', 'hide_featured_term' ), 10, 2 );
|
||||
remove_filter( 'get_the_terms', array( 'Featured_Content', 'hide_the_featured_term' ), 10, 3 );
|
||||
}
|
||||
Reference in New Issue
Block a user