[wp-trac] [WordPress Trac] #38401: PHP warning by WP_REST_Posts_Controller::prepare_items_query(): array_flip() can only flip string and integer values
WordPress Trac
noreply at wordpress.org
Sun Oct 23 12:22:35 UTC 2016
#38401: PHP warning by WP_REST_Posts_Controller::prepare_items_query():
array_flip() can only flip string and integer values
--------------------------+--------------------
Reporter: ocean90 | Owner:
Type: defect (bug) | Status: new
Priority: normal | Milestone: 4.7
Component: REST API | Version: trunk
Severity: normal | Resolution:
Keywords: close | Focuses:
--------------------------+--------------------
Changes (by kovshenin):
* keywords: needs-patch => close
Comment:
`query_vars` is an array where each value is a query var and keys are not
relevant. The way the handbook plugin whitelists a query var looks wrong,
it should be:
{{{
$public_query_vars[] = 'is_handbook_root';
}}}
I also don't see why the query var should be public in that particular
case, I don't see any custom rewrite rules using it, so it looks like a
completely internal query var to me, but I may be missing something.
--
Ticket URL: <https://core.trac.wordpress.org/ticket/38401#comment:2>
WordPress Trac <https://core.trac.wordpress.org/>
WordPress publishing platform
More information about the wp-trac
mailing list