Add name to list of allowed keys. Props MarcusPope. fixes #18638
git-svn-id: https://develop.svn.wordpress.org/trunk@18838 602fd350-edb4-49c9-b593-d223f7449a82
This commit is contained in:
parent
e8fd0746c8
commit
cff31ae5f5
@ -2329,7 +2329,7 @@ class WP_Query {
|
||||
$orderby = '';
|
||||
} else {
|
||||
// Used to filter values
|
||||
$allowed_keys = array('author', 'date', 'title', 'modified', 'menu_order', 'parent', 'ID', 'rand', 'comment_count');
|
||||
$allowed_keys = array('name', 'author', 'date', 'title', 'modified', 'menu_order', 'parent', 'ID', 'rand', 'comment_count');
|
||||
if ( !empty($q['meta_key']) ) {
|
||||
$allowed_keys[] = $q['meta_key'];
|
||||
$allowed_keys[] = 'meta_value';
|
||||
|
Loading…
Reference in New Issue
Block a user