sal/class.json-api-site-base.php 1 location
|
@@ 200-205 (lines=6) @@
|
197 |
|
return false; |
198 |
|
} |
199 |
|
|
200 |
|
if ( 'inherit' === $post->post_status ) { |
201 |
|
$parent_post = get_post( $post->post_parent ); |
202 |
|
$post_status_obj = get_post_status_object( $parent_post->post_status ); |
203 |
|
} else { |
204 |
|
$post_status_obj = get_post_status_object( $post->post_status ); |
205 |
|
} |
206 |
|
|
207 |
|
$authorized = ( |
208 |
|
$post_status_obj->public || |
class.json-api-endpoints.php 1 location
|
@@ 959-964 (lines=6) @@
|
956 |
|
return false; |
957 |
|
} |
958 |
|
|
959 |
|
if ( 'inherit' === $post->post_status ) { |
960 |
|
$parent_post = get_post( $post->post_parent ); |
961 |
|
$post_status_obj = get_post_status_object( $parent_post->post_status ); |
962 |
|
} else { |
963 |
|
$post_status_obj = get_post_status_object( $post->post_status ); |
964 |
|
} |
965 |
|
|
966 |
|
if ( !$post_status_obj->public ) { |
967 |
|
if ( is_user_logged_in() ) { |