[wp-trac] [WordPress Trac] #59722: regression: class-wp-rest-server.php
WordPress Trac
noreply at wordpress.org
Tue Oct 24 20:16:58 UTC 2023
#59722: regression: class-wp-rest-server.php
--------------------------+-----------------------------
Reporter: perrelet | Owner: (none)
Type: defect (bug) | Status: new
Priority: normal | Milestone: Awaiting Review
Component: General | Version: trunk
Severity: major | Keywords:
Focuses: rest-api |
--------------------------+-----------------------------
In
https://github.com/WordPress/WordPress/commit/3f1e6a6a5031b319fd5ebfaaf6598fec3fe78fb1
The `rest_send_nocache_headers` block is moved after
`rest_pre_serve_request`.
However this renders `rest_pre_serve_request` useless because
`rest_send_nocache_headers` sends / removes http headers. As a result,
using `rest_pre_serve_request` for it's intended purpose (to manually send
the request) results in `Cannot modify header information - headers
already sent`.
Suggest moving the `rest_send_nocache_headers` block before the
`rest_pre_serve_request` filter.
--
Ticket URL: <https://core.trac.wordpress.org/ticket/59722>
WordPress Trac <https://core.trac.wordpress.org/>
WordPress publishing platform
More information about the wp-trac
mailing list