Commit edfc2b0
committed
REST API: Remove post status prefix from REST API responses.
When using the /posts or /pages endpoints, for private posts or pages, you get the following title property: { raw: "Some title", rendered: "Private: Some title" }
this commit removes the prefix from rendered private posts titles (just like what we do for protected posts)
Props youknowriad, swissspidy, timothyblynjacobs, sergeybiryukov, ramonopoly.
Fixes #61639.
git-svn-id: https://develop.svn.wordpress.org/trunk@58783 602fd350-edb4-49c9-b593-d223f7449a821 parent fc33ab6 commit edfc2b0
File tree
6 files changed
+22
-10
lines changed- src/wp-includes/rest-api
- endpoints
- search
- tests/phpunit
- includes
- tests/rest-api
6 files changed
+22
-10
lines changedLines changed: 2 additions & 0 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
327 | 327 | | |
328 | 328 | | |
329 | 329 | | |
| 330 | + | |
330 | 331 | | |
331 | 332 | | |
332 | 333 | | |
333 | 334 | | |
| 335 | + | |
334 | 336 | | |
335 | 337 | | |
336 | 338 | | |
| |||
Lines changed: 2 additions & 0 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
510 | 510 | | |
511 | 511 | | |
512 | 512 | | |
| 513 | + | |
513 | 514 | | |
514 | 515 | | |
515 | 516 | | |
516 | 517 | | |
517 | 518 | | |
518 | 519 | | |
519 | 520 | | |
| 521 | + | |
520 | 522 | | |
521 | 523 | | |
522 | 524 | | |
| |||
Lines changed: 7 additions & 5 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1844 | 1844 | | |
1845 | 1845 | | |
1846 | 1846 | | |
| 1847 | + | |
1847 | 1848 | | |
1848 | 1849 | | |
1849 | 1850 | | |
1850 | 1851 | | |
| 1852 | + | |
1851 | 1853 | | |
1852 | 1854 | | |
1853 | 1855 | | |
| |||
2047 | 2049 | | |
2048 | 2050 | | |
2049 | 2051 | | |
2050 | | - | |
| 2052 | + | |
2051 | 2053 | | |
2052 | | - | |
2053 | | - | |
2054 | | - | |
| 2054 | + | |
| 2055 | + | |
| 2056 | + | |
2055 | 2057 | | |
2056 | 2058 | | |
2057 | 2059 | | |
2058 | | - | |
| 2060 | + | |
2059 | 2061 | | |
2060 | 2062 | | |
2061 | 2063 | | |
| |||
Lines changed: 7 additions & 5 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
132 | 132 | | |
133 | 133 | | |
134 | 134 | | |
| 135 | + | |
135 | 136 | | |
136 | 137 | | |
| 138 | + | |
137 | 139 | | |
138 | 140 | | |
139 | 141 | | |
| |||
183 | 185 | | |
184 | 186 | | |
185 | 187 | | |
186 | | - | |
| 188 | + | |
187 | 189 | | |
188 | | - | |
189 | | - | |
190 | | - | |
| 190 | + | |
| 191 | + | |
| 192 | + | |
191 | 193 | | |
192 | 194 | | |
193 | 195 | | |
194 | | - | |
| 196 | + | |
195 | 197 | | |
196 | 198 | | |
197 | 199 | | |
| |||
Lines changed: 2 additions & 0 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
107 | 107 | | |
108 | 108 | | |
109 | 109 | | |
| 110 | + | |
110 | 111 | | |
111 | 112 | | |
| 113 | + | |
112 | 114 | | |
113 | 115 | | |
114 | 116 | | |
| |||
Lines changed: 2 additions & 0 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
862 | 862 | | |
863 | 863 | | |
864 | 864 | | |
| 865 | + | |
865 | 866 | | |
866 | 867 | | |
| 868 | + | |
867 | 869 | | |
868 | 870 | | |
869 | 871 | | |
| |||
0 commit comments