X-Git-Url: https://scripts.mit.edu/gitweb/autoinstalls/wordpress.git/blobdiff_plain/6c8f14c09105d0afa4c1574215c59b5021040e76..refs/tags/wordpress-3.5.1:/wp-content/plugins/akismet/admin.php diff --git a/wp-content/plugins/akismet/admin.php b/wp-content/plugins/akismet/admin.php index aa30cde7..9d7673f5 100644 --- a/wp-content/plugins/akismet/admin.php +++ b/wp-content/plugins/akismet/admin.php @@ -23,7 +23,6 @@ function akismet_admin_init() { $hook = get_plugin_page_hook( 'akismet-stats-display', 'index.php' ); else $hook = 'dashboard_page_akismet-stats-display'; - add_action('admin_head-'.$hook, 'akismet_stats_script'); add_meta_box('akismet-status', __('Comment History'), 'akismet_comment_status_meta_box', 'comment', 'normal'); } add_action('admin_init', 'akismet_admin_init'); @@ -56,7 +55,7 @@ $akismet_nonce = 'akismet-update-key'; function akismet_plugin_action_links( $links, $file ) { if ( $file == plugin_basename( dirname(__FILE__).'/akismet.php' ) ) { - $links[] = ''.__('Settings').''; + $links[] = ''.__( 'Settings' ).''; } return $links; @@ -240,23 +239,6 @@ function akismet_conf() { -
- +
get_var( $wpdb->prepare( "SELECT COUNT(*) FROM $wpdb->commentmeta WHERE meta_key = 'akismet_error'" ) ); + $waiting = $wpdb->get_var( "SELECT COUNT(*) FROM $wpdb->commentmeta WHERE meta_key = 'akismet_error'" ); $next_check = wp_next_scheduled('akismet_schedule_cron_recheck'); if ( $waiting > 0 && $next_check > time() ) echo " @@ -741,7 +723,8 @@ function akismet_recheck_queue() { delete_comment_meta( $c['comment_ID'], 'akismet_rechecking' ); } - wp_safe_redirect( $_SERVER['HTTP_REFERER'] ); + $redirect_to = isset( $_SERVER['HTTP_REFERER'] ) ? $_SERVER['HTTP_REFERER'] : admin_url( 'edit-comments.php' ); + wp_safe_redirect( $redirect_to ); exit; }