diff --git wp-includes/comment.php wp-includes/comment.php
index b4f4125..0e92a4b 100644
|
|
|
function do_trackbacks($post_id) { |
| 1377 | 1377 | * @return int Same as Post ID from parameter |
| 1378 | 1378 | */ |
| 1379 | 1379 | function generic_ping($post_id = 0) { |
| | 1380 | $last_ping = get_option('generic_ping_last'); |
| | 1381 | |
| | 1382 | if ( $last_ping === false ) { |
| | 1383 | add_option('generic_ping_last', time()); |
| | 1384 | } else { |
| | 1385 | update_option('generic_ping_last', time()); |
| | 1386 | } |
| | 1387 | |
| 1380 | 1388 | $services = get_option('ping_sites'); |
| 1381 | 1389 | |
| 1382 | 1390 | $services = explode("\n", $services); |
diff --git wp-includes/post.php wp-includes/post.php
index 0c0ba46..cfe755f 100644
|
|
|
function _transition_post_status($new_status, $old_status, $post) { |
| 3275 | 3275 | $wpdb->update( $wpdb->posts, array( 'guid' => get_permalink( $post->ID ) ), array( 'ID' => $post->ID ) ); |
| 3276 | 3276 | do_action('private_to_published', $post->ID); // Deprecated, use private_to_publish |
| 3277 | 3277 | // do generic pings once per hour at most |
| 3278 | | if ( !wp_next_scheduled('do_generic_ping') ) |
| 3279 | | wp_schedule_single_event(time() + 3600, 'do_generic_ping'); |
| | 3278 | if ( !wp_next_scheduled('do_generic_ping') ) { |
| | 3279 | $last_ping = get_option('generic_ping_last', 0); |
| | 3280 | wp_schedule_single_event(max(time() + 60, $last_ping + 1800), 'do_generic_ping'); |
| | 3281 | } |
| 3280 | 3282 | } |
| 3281 | 3283 | |
| 3282 | 3284 | // Always clears the hook in case the post status bounced from future to draft. |