[wp-trac] [WordPress Trac] #31521: wp_title if archive of year w/o permalink fires php notice in locale.php

WordPress Trac noreply at wordpress.org
Thu Nov 11 00:18:11 UTC 2021


#31521: wp_title if archive of year w/o permalink fires php notice in locale.php
-------------------------------------------------+-------------------------
 Reporter:  michelwppi                           |       Owner:
                                                 |  hellofromTonya
     Type:  defect (bug)                         |      Status:  assigned
 Priority:  normal                               |   Milestone:  5.9
Component:  General                              |     Version:  4.1.1
 Severity:  normal                               |  Resolution:
 Keywords:  good-first-bug has-patch has-        |     Focuses:  template
  screenshots needs-testing has-unit-tests       |
  commit                                         |
-------------------------------------------------+-------------------------
Changes (by hellofromTonya):

 * keywords:  good-first-bug has-patch has-screenshots needs-testing has-
     unit-tests =>
     good-first-bug has-patch has-screenshots needs-testing has-unit-tests
     commit


Comment:

 Hello folks,

 I too was able to reproduce the issue and [attachment:"31521.4.diff"]
 resolves it.

 I created [https://github.com/WordPress/wordpress-develop/pull/1861 PR
 1861] which:

 * adds unit tests (which do fail when the fix is not applied)
 * applies the [attachment:"31521.4.diff"] fix
 * for the `$title` concatenated string: puts each date part on a separate
 line for improved readability

 Marking for `commit`. Props to @costdev for the code review.

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


More information about the wp-trac mailing list