Pings to the people. Return to pinging for updates to published posts. see #6698

git-svn-id: http://svn.automattic.com/wordpress/trunk@11734 1a063a9b-81f0-0310-95a4-ce76da25c4cd
This commit is contained in:
ryan
2009-07-21 23:09:47 +00:00
parent 98e73f0c98
commit f7e02a7c22
3 changed files with 3 additions and 12 deletions

View File

@@ -3274,15 +3274,6 @@ function _transition_post_status($new_status, $old_status, $post) {
if ( '' == get_the_guid($post->ID) )
$wpdb->update( $wpdb->posts, array( 'guid' => get_permalink( $post->ID ) ), array( 'ID' => $post->ID ) );
do_action('private_to_published', $post->ID); // Deprecated, use private_to_publish
// do generic pings once per half hour at most
if ( !wp_next_scheduled('do_generic_ping') ) {
$schedule = time();
$last_ping = get_transient('generic_ping_last');
if ($last_ping) {
$schedule = max($schedule, $last_ping + 1800);
}
wp_schedule_single_event($schedule, 'do_generic_ping');
}
}
// Always clears the hook in case the post status bounced from future to draft.