[wp-trac] [WordPress Trac] #45361: Integer menu slugs should not be supported

WordPress Trac noreply at wordpress.org
Sat Feb 2 07:50:31 UTC 2019


#45361: Integer menu slugs should not be supported
--------------------------+-----------------------
 Reporter:  desrosj       |       Owner:  audrasjb
     Type:  defect (bug)  |      Status:  assigned
 Priority:  normal        |   Milestone:  5.2
Component:  Menus         |     Version:
 Severity:  normal        |  Resolution:
 Keywords:  has-patch     |     Focuses:
--------------------------+-----------------------
Changes (by audrasjb):

 * keywords:  needs-patch => has-patch
 * milestone:  Future Release => 5.2


Comment:

 Hi,

 `45361.diff` adds a `_doing_it_wrong()` warning message:

 "Menu location slug (key) for menu "%s" should not be a int."

 `%s` is the ''value'' of the `$locations` array, not the ''key'', since
 numeric indexes can be different from what developers used.

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


More information about the wp-trac mailing list