[wp-trac] [WordPress Trac] #45017: REST API: Expose permalink_template in the Posts controller
WordPress Trac
noreply at wordpress.org
Thu Oct 11 22:09:57 UTC 2018
#45017: REST API: Expose permalink_template in the Posts controller
--------------------------------------+-----------------------
Reporter: danielbachhuber | Owner: (none)
Type: enhancement | Status: new
Priority: normal | Milestone: 5.0
Component: REST API | Version:
Severity: normal | Resolution:
Keywords: has-patch has-unit-tests | Focuses: rest-api
--------------------------------------+-----------------------
Comment (by danielbachhuber):
In `45017.4.diff`, I've:
1. Cleaned up the tests to be a bit more literal and understandable.
2. Fixed the response data inclusion to respect any `?_fields=` defined
for the request.
3. Updated more tests accordingly so the entire suite passes.
4. Disabled the assertion with `filter_rest_url_for_leading_slash` when we
have pretty permalinks. The origin was [https://github.com/WP-API/WP-
API/pull/2428 WP-API/WP-API#2428] which wasn't designed for tests with
pretty permalinks.
I've also verified Gutenberg continues to work as expected with this
patch.
--
Ticket URL: <https://core.trac.wordpress.org/ticket/45017#comment:9>
WordPress Trac <https://core.trac.wordpress.org/>
WordPress publishing platform
More information about the wp-trac
mailing list