Wordpress/tests
Pascal Birchler 3f200a7c35 REST API: Confirm the parent post object of an attachment exists in `WP_REST_Posts_Controller::check_read_permission()`.
Avoid a PHP Error when attempting to embed the parent post of an attachment, when the parent post ID is invalid. Instead check if the parent post 
object exists before checking the read permission for the parent post.

Props GhostToast.
Fixes #39881. 

Merges [40306] to the 4.7 branch.


git-svn-id: https://develop.svn.wordpress.org/branches/4.7@40337 602fd350-edb4-49c9-b593-d223f7449a82
2017-03-27 09:23:05 +00:00
..
phpunit REST API: Confirm the parent post object of an attachment exists in `WP_REST_Posts_Controller::check_read_permission()`. 2017-03-27 09:23:05 +00:00
qunit REST API: Add `gmt_offset` and `timezone_string` to the base `/wp-json` response. 2017-03-27 07:08:54 +00:00