sal/class.json-api-site-base.php 1 location
|
@@ 193-198 (lines=6) @@
|
| 190 |
|
return false; |
| 191 |
|
} |
| 192 |
|
|
| 193 |
|
if ( 'inherit' === $post->post_status ) { |
| 194 |
|
$parent_post = get_post( $post->post_parent ); |
| 195 |
|
$post_status_obj = get_post_status_object( $parent_post->post_status ); |
| 196 |
|
} else { |
| 197 |
|
$post_status_obj = get_post_status_object( $post->post_status ); |
| 198 |
|
} |
| 199 |
|
|
| 200 |
|
$authorized = ( |
| 201 |
|
$post_status_obj->public || |
class.json-api-endpoints.php 1 location
|
@@ 972-977 (lines=6) @@
|
| 969 |
|
return false; |
| 970 |
|
} |
| 971 |
|
|
| 972 |
|
if ( 'inherit' === $post->post_status ) { |
| 973 |
|
$parent_post = get_post( $post->post_parent ); |
| 974 |
|
$post_status_obj = get_post_status_object( $parent_post->post_status ); |
| 975 |
|
} else { |
| 976 |
|
$post_status_obj = get_post_status_object( $post->post_status ); |
| 977 |
|
} |
| 978 |
|
|
| 979 |
|
if ( !$post_status_obj->public ) { |
| 980 |
|
if ( is_user_logged_in() ) { |