|
@@ 338-345 (lines=8) @@
|
| 335 |
|
return $post; |
| 336 |
|
} |
| 337 |
|
|
| 338 |
|
function get_posts( $args ) { |
| 339 |
|
list( $post_ids ) = $args; |
| 340 |
|
$post_ids = array_map( 'intval', (array) $post_ids ); |
| 341 |
|
$jp = Jetpack::init(); |
| 342 |
|
$sync_data = $jp->sync->get_content( array( 'posts' => $post_ids ) ); |
| 343 |
|
|
| 344 |
|
return $sync_data; |
| 345 |
|
} |
| 346 |
|
|
| 347 |
|
function get_comment( $id ) { |
| 348 |
|
if ( !$id = (int) $id ) { |
|
@@ 366-373 (lines=8) @@
|
| 363 |
|
return $comment; |
| 364 |
|
} |
| 365 |
|
|
| 366 |
|
function get_comments( $args ) { |
| 367 |
|
list( $comment_ids ) = $args; |
| 368 |
|
$comment_ids = array_map( 'intval', (array) $comment_ids ); |
| 369 |
|
$jp = Jetpack::init(); |
| 370 |
|
$sync_data = $jp->sync->get_content( array( 'comments' => $comment_ids ) ); |
| 371 |
|
|
| 372 |
|
return $sync_data; |
| 373 |
|
} |
| 374 |
|
|
| 375 |
|
function update_attachment_parent( $args ) { |
| 376 |
|
$attachment_id = (int) $args[0]; |