[wp-trac] [WordPress Trac] #33045: New conditional tags for child/parent pages

WordPress Trac noreply at wordpress.org
Wed Jan 27 23:06:04 UTC 2021


#33045: New conditional tags for child/parent pages
-------------------------------------------------+-------------------------
 Reporter:  ramiy                                |       Owner:  audrasjb
     Type:  enhancement                          |      Status:  accepted
 Priority:  normal                               |   Milestone:  5.7
Component:  Posts, Post Types                    |     Version:
 Severity:  normal                               |  Resolution:
 Keywords:  has-patch needs-dev-note needs-docs  |     Focuses:  template
  has-unit-tests                                 |
-------------------------------------------------+-------------------------
Changes (by xkon):

 * keywords:  has-patch needs-dev-note needs-docs needs-unit-tests => has-
     patch needs-dev-note needs-docs has-unit-tests


Comment:

 [attachment:"33045.9.diff"] adds unit tests, also renames the functions
 into `has_parent_post()` & `get_parent_post()` as mentioned by
 @johnbillion in comment [comment:18] as it makes more sense.

 I believe this is ready for a review if I didn't miss anything extra from
 the previous comments.

-- 
Ticket URL: <https://core.trac.wordpress.org/ticket/33045#comment:39>
WordPress Trac <https://core.trac.wordpress.org/>
WordPress publishing platform


More information about the wp-trac mailing list