[wp-trac] [WordPress Trac] #44764: Missing slash between protocol and domain in fallback of wp.api.utils.getRootUrl()

WordPress Trac noreply at wordpress.org
Sat Aug 11 18:50:26 UTC 2018


#44764: Missing slash between protocol and domain in fallback of
wp.api.utils.getRootUrl()
---------------------------------------------+-----------------------------
 Reporter:  ocean90                          |       Owner:  kadamwhite
     Type:  defect (bug)                     |      Status:  closed
 Priority:  normal                           |   Milestone:  5.0
Component:  REST API                         |     Version:  4.7
 Severity:  normal                           |  Resolution:  fixed
 Keywords:  good-first-bug has-patch commit  |     Focuses:  javascript,
                                             |  rest-api
---------------------------------------------+-----------------------------
Changes (by kadamwhite):

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


Comment:

 In [changeset:"43566" 43566]:
 {{{
 #!CommitTicketReference repository="" revision="43566"
 REST API: generate a valid fallback URI in wp.api.utils.getRootURL.

 When window.location.origin isn't set, correctly insert two slashes
 between the protocol and host when constructing the fallback URL.

 props abdullahramzan.
 Fixes #44764.
 }}}

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


More information about the wp-trac mailing list