[wp-trac] [WordPress Trac] #34373: Don't set is_home=>true in WP_Query during REST request
WordPress Trac
noreply at wordpress.org
Wed Nov 18 21:05:29 UTC 2015
#34373: Don't set is_home=>true in WP_Query during REST request
--------------------------------------+------------------
Reporter: danielbachhuber | Owner:
Type: defect (bug) | Status: new
Priority: normal | Milestone: 4.4
Component: REST API | Version:
Severity: normal | Resolution:
Keywords: dev-feedback needs-patch | Focuses:
--------------------------------------+------------------
Comment (by danielbachhuber):
34373.2.diff bails on setting `is_home=>true` when `defined(
'REST_REQUEST' ) && REST_REQUEST`
While this approach adds more ugliness to an already ugly conditional,
it's also the most future proof. We solve most of the immediate problem
while keeping the possibility of introducing `WP_Query::$is_rest` in the
future, or changing how variables are set.
--
Ticket URL: <https://core.trac.wordpress.org/ticket/34373#comment:8>
WordPress Trac <https://core.trac.wordpress.org/>
WordPress publishing platform
More information about the wp-trac
mailing list