[wp-trac] [WordPress Trac] #56992: The Loop displays incorrect data for queries started with `fields => 'id=>parent'`.
WordPress Trac
noreply at wordpress.org
Sun Mar 16 20:50:31 UTC 2025
#56992: The Loop displays incorrect data for queries started with `fields =>
'id=>parent'`.
--------------------------------------+----------------------------
Reporter: peterwilsoncc | Owner: peterwilsoncc
Type: defect (bug) | Status: reopened
Priority: normal | Milestone: 6.8
Component: Query | Version: 3.1
Severity: normal | Resolution:
Keywords: has-patch has-unit-tests | Focuses: performance
--------------------------------------+----------------------------
Comment (by joemcgill):
@SirLouen passing something other than "all" to `fields` is used for
different purposes than to set up a loop. However, there may be cases
where someone has performed a query in that way and then subsequently
passed off the query to a loop. I'm not in support of throwing a
`_doing_it_wrong` warning in this case, as the software cannot know the
intent the developer had in doing things this way and throwing a warning
would be presumptive, at best.
--
Ticket URL: <https://core.trac.wordpress.org/ticket/56992#comment:52>
WordPress Trac <https://core.trac.wordpress.org/>
WordPress publishing platform
More information about the wp-trac
mailing list