Skip to content

Patch php-wasm/universal to fix QUERY_STRING - #1356

Merged
sejas merged 3 commits into
trunkfrom
add/STU-445-patch-playground-1.0.30-fix-query-string
May 8, 2025
Merged

Patch php-wasm/universal to fix QUERY_STRING#1356
sejas merged 3 commits into
trunkfrom
add/STU-445-patch-playground-1.0.30-fix-query-string

Conversation

@sejas

@sejas sejas commented May 8, 2025

Copy link
Copy Markdown
Member

Related issues

Proposed Changes

Testing Instructions

  • Run npm start
  • Create a new site, or start an existing site with latest WordPress (6.8.1)
  • Navigate to wp-admin
  • Open Appearance > Editor
  • Observe there are no warnings related to QUERY_STRING. You can inspect the source of the website to make sure.

Screenshot 2025-05-08 at 15 05 23

Pre-merge Checklist

  • Have you checked for TypeScript, React or other console errors?
Comment thread patches/@php-wasm+universal+1.0.30.patch
@wojtekn
wojtekn requested a review from a team May 8, 2025 14:18
@wojtekn

wojtekn commented May 8, 2025

Copy link
Copy Markdown
Contributor

@sejas I reproduced the error using 1.5.1-beta1 and confirmed that this PR fixes it. Thanks for preparing the patch!

@wojtekn wojtekn left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Works well

@sejas
sejas merged commit 511afbc into trunk May 8, 2025
@sejas
sejas deleted the add/STU-445-patch-playground-1.0.30-fix-query-string branch May 8, 2025 15:20
Comment on lines +22 to +38
- if (this[__private__dont__use].ccall(
- "wasm_set_request_uri",
- null,
- [STRING],
- [t]
- ), t.includes("?")) {
- const e = t.substring(t.indexOf("?") + 1);
+ this[__private__dont__use].ccall(
+ "wasm_set_request_uri",
+ null,
+ [STRING],
+ [t]
+ );
+ let e = '';
+ if (t.includes("?")) {
+ e = t.substring(t.indexOf("?") + 1);
+ }

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This code is not actually executed; it's the non-minimized version of the patch. I modified it just for reference.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

2 participants