Commit 5930f08
committed
Formatting: Deprecate the
This deprecates `addslashes_gpc()` in favor of `wp_slash()`, as the former is just a wrapper for the latter. The three remaining uses of `addslashes_gpc()` (in `WP_Query`) have been replaced with `wp_slash()`. Unit tests are added to verify that they have the same behavior.
Developed in WordPress#10771
Follow-up to [23591], [23555].
Props rutviksavsani, audrasjb, westonruter, mindctrl, johnbillion.
See #21767.
Fixes #64539.
git-svn-id: https://develop.svn.wordpress.org/trunk@61590 602fd350-edb4-49c9-b593-d223f7449a82addslashes_gpc() function.1 parent e36be00 commit 5930f08
4 files changed
Lines changed: 54 additions & 16 deletions
File tree
- src/wp-includes
- tests/phpunit/tests/formatting
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
2386 | 2386 | | |
2387 | 2387 | | |
2388 | 2388 | | |
2389 | | - | |
| 2389 | + | |
2390 | 2390 | | |
2391 | 2391 | | |
2392 | 2392 | | |
| |||
2505 | 2505 | | |
2506 | 2506 | | |
2507 | 2507 | | |
2508 | | - | |
| 2508 | + | |
2509 | 2509 | | |
2510 | 2510 | | |
2511 | 2511 | | |
| |||
2518 | 2518 | | |
2519 | 2519 | | |
2520 | 2520 | | |
2521 | | - | |
| 2521 | + | |
2522 | 2522 | | |
2523 | 2523 | | |
2524 | 2524 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
6480 | 6480 | | |
6481 | 6481 | | |
6482 | 6482 | | |
| 6483 | + | |
| 6484 | + | |
| 6485 | + | |
| 6486 | + | |
| 6487 | + | |
| 6488 | + | |
| 6489 | + | |
| 6490 | + | |
| 6491 | + | |
| 6492 | + | |
| 6493 | + | |
| 6494 | + | |
| 6495 | + | |
| 6496 | + | |
| 6497 | + | |
| 6498 | + | |
| 6499 | + | |
| 6500 | + | |
6483 | 6501 | | |
6484 | 6502 | | |
6485 | 6503 | | |
| |||
6508 | 6526 | | |
6509 | 6527 | | |
6510 | 6528 | | |
6511 | | - | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
2837 | 2837 | | |
2838 | 2838 | | |
2839 | 2839 | | |
2840 | | - | |
2841 | | - | |
2842 | | - | |
2843 | | - | |
2844 | | - | |
2845 | | - | |
2846 | | - | |
2847 | | - | |
2848 | | - | |
2849 | | - | |
2850 | | - | |
2851 | | - | |
2852 | 2840 | | |
2853 | 2841 | | |
2854 | 2842 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
101 | 101 | | |
102 | 102 | | |
103 | 103 | | |
| 104 | + | |
| 105 | + | |
| 106 | + | |
| 107 | + | |
| 108 | + | |
| 109 | + | |
| 110 | + | |
| 111 | + | |
| 112 | + | |
| 113 | + | |
| 114 | + | |
| 115 | + | |
| 116 | + | |
| 117 | + | |
| 118 | + | |
| 119 | + | |
| 120 | + | |
| 121 | + | |
| 122 | + | |
| 123 | + | |
| 124 | + | |
| 125 | + | |
| 126 | + | |
| 127 | + | |
| 128 | + | |
| 129 | + | |
| 130 | + | |
| 131 | + | |
| 132 | + | |
| 133 | + | |
| 134 | + | |
| 135 | + | |
| 136 | + | |
104 | 137 | | |
0 commit comments