[wp-trac] [WordPress Trac] #55699: posts_join_request filter is broken
WordPress Trac
noreply at wordpress.org
Tue May 10 10:17:39 UTC 2022
#55699: posts_join_request filter is broken
-------------------------------------------------+-------------------------
Reporter: 5um17 | Owner:
| SergeyBiryukov
Type: defect (bug) | Status: reopened
Priority: normal | Milestone: 6.0
Component: Query | Version: trunk
Severity: normal | Resolution:
Keywords: has-patch has-unit-tests changes- | Focuses:
requested |
-------------------------------------------------+-------------------------
Comment (by SergeyBiryukov):
Replying to [comment:12 peterwilsoncc]:
> As a defensive coding measure, two variables need to be used one for the
names, one for the values of the clauses.
>
> I see in the original patch the suggestion was pieces and clauses. I
think this is preferable to what is in trunk at the moment, despite the
inconsistency with other query classes.
Sounds good, though if we're going to restore the `$pieces` name, I would
ideally prefer to do that consistently for all query classes, essentially
reverting [52974], as I don't see a reason for them to be different, and
appreciate consistency where possible. In hindsight, the reason for
[52974] was that `$clauses` seemed like a better name than `$pieces` for
the `*_clauses` filter parameters, and I think that part can remain.
Does [attachment:"55699.5.diff"] address the concern?
--
Ticket URL: <https://core.trac.wordpress.org/ticket/55699#comment:13>
WordPress Trac <https://core.trac.wordpress.org/>
WordPress publishing platform
More information about the wp-trac
mailing list