getWPAdminURL assumes you are in wp-admin #7095
Labels
Good First Issue
An issue that's suitable for someone looking to contribute for the first time
REST API Interaction
Related to REST API
[Type] Bug
An existing feature does not function as intended
Milestone
The true bug is when using Gutenberg out of the /wp-admin/ , for example as a front-end editor within P2 theme and the user selects "Move to Trash" the TRASH_POST_SUCCESS effect redirects the browser location to"
However,
getWPAdminURL()
does not actually get the /wp-admin/ URL, it only adds query parameters to the page passed in, which works if the editor is already in /wp-admin/ but not if it elsewhere.To Reproduce
Steps to reproduce the behavior:
See
getWPAdminURL
function ineditor/utils/url.js
does not return the URL of a wp-admin pageExpected behavior
The function should return a full relative link to /wp-admin/
The text was updated successfully, but these errors were encountered: