class.json-api-endpoints.php 1 location
|
@@ 1287-1289 (lines=3) @@
|
1284 |
|
return new WP_Error( 'unauthorized', 'User cannot edit taxonomy', 403 ); |
1285 |
|
break; |
1286 |
|
case 'display' : |
1287 |
|
if ( -1 == get_option( 'blog_public' ) && ! current_user_can( 'read' ) ) { |
1288 |
|
return new WP_Error( 'unauthorized', 'User cannot view taxonomy', 403 ); |
1289 |
|
} |
1290 |
|
break; |
1291 |
|
default : |
1292 |
|
return new WP_Error( 'invalid_context', 'Invalid API CONTEXT', 400 ); |
class.json-api.php 1 location
|
@@ 546-548 (lines=3) @@
|
543 |
|
return new WP_Error( 'unauthorized', 'User cannot access this restricted blog', 403 ); |
544 |
|
} |
545 |
|
|
546 |
|
if ( -1 == get_option( 'blog_public' ) && !current_user_can( 'read' ) ) { |
547 |
|
return new WP_Error( 'unauthorized', 'User cannot access this private blog.', 403 ); |
548 |
|
} |
549 |
|
|
550 |
|
return $blog_id; |
551 |
|
} |