[wp-trac] [WordPress Trac] #63224: Undefined array key "QUERY_STRING" in _wp_get_site_editor_redirection_url()
WordPress Trac
noreply at wordpress.org
Sat Apr 5 15:15:51 UTC 2025
#63224: Undefined array key "QUERY_STRING" in _wp_get_site_editor_redirection_url()
-------------------------------------------------+-------------------------
Reporter: akshaydhere | Owner: (none)
Type: defect (bug) | Status: reopened
Priority: normal | Milestone: 6.8
Component: Editor | Version: trunk
Severity: normal | Resolution:
Keywords: has-patch needs-testing needs- | Focuses:
testing-info |
-------------------------------------------------+-------------------------
Comment (by wildworks):
The environment in which I was able to reproduce this is
[https://developer.wordpress.com/studio/ Studio].
Presumably, whether `$_SERVER['QUERY_STRING']` becomes undefined or an
empty string when the query parameter is not present in the URL depends on
the server type and settings.
However, I don't understand why this server variable is being checked in
the first place. I read all the core ticket and Gutenberg PR related to
this code, but I couldn't find out the reason.
In my opinion, this check should be able to be removed. Or is it a
safeguard in case this internal function is called unintentionally from
some special circumstances?
cc @joemcgill @Mamaduka @peterwilsoncc for visibility
--
Ticket URL: <https://core.trac.wordpress.org/ticket/63224#comment:11>
WordPress Trac <https://core.trac.wordpress.org/>
WordPress publishing platform
More information about the wp-trac
mailing list