Commit 5108baf
committed
Refactor query string parsing for RelayState redirect
This commit is replacing `parse_url` by `wp_parse_url` function, which is a WordPress wrapper for PHP inconsistencies. While working on related code, this PR is cleaning up the code.
* There is no need to parse and obtain whole url. Passing PHP_URL_QUERY to `wp_parse_url` function gets us just the bit we need.
* There is no need to define the `$result` param prior calling `parse_str` function.
* variable `$target` is not being used. Thus has been removed.1 parent 1e07ba4 commit 5108baf
1 file changed
Lines changed: 2 additions & 4 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
291 | 291 | | |
292 | 292 | | |
293 | 293 | | |
294 | | - | |
295 | | - | |
296 | | - | |
297 | | - | |
| 294 | + | |
| 295 | + | |
298 | 296 | | |
299 | 297 | | |
300 | 298 | | |
| |||
0 commit comments