[wp-trac] [WordPress Trac] #48530: Match REST API route by namespace before performing regex checks

WordPress Trac noreply at wordpress.org
Mon Feb 24 18:05:26 UTC 2020


#48530: Match REST API route by namespace before performing regex checks
-------------------------------------------------+-------------------------
 Reporter:  TimothyBlynJacobs                    |       Owner:  kadamwhite
     Type:  enhancement                          |      Status:  closed
 Priority:  normal                               |   Milestone:  5.4
Component:  REST API                             |     Version:  4.4
 Severity:  normal                               |  Resolution:  fixed
 Keywords:  has-patch has-unit-tests needs-dev-  |     Focuses:
  note                                           |  performance
-------------------------------------------------+-------------------------
Changes (by kadamwhite):

 * status:  reopened => closed
 * resolution:   => fixed


Comment:

 In [changeset:"47351" 47351]:
 {{{
 #!CommitTicketReference repository="" revision="47351"
 REST API: Fix namespace shadowing issue in route matching logic.

 Following [47260] a namespace such as "test-ns" prevents any namespace
 such as "test-ns/v1" from being found when matching routes.
 While not best practice, this was an unintentional back-compat break; this
 patch restores the original behavior.

 Props david.binda, TimothyBlynJacobs.
 Fixes #48530.
 }}}

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


More information about the wp-trac mailing list