diff --git a/wp-admin/admin.php b/wp-admin/admin.php
index 88a4aa4..6591e9b 100644
a
|
b
|
require_once(dirname(dirname(__FILE__)) . '/wp-load.php'); |
32 | 32 | |
33 | 33 | nocache_headers(); |
34 | 34 | |
35 | | if ( get_option('db_upgraded') ) { |
| 35 | if ( ! wp_doing_ajax() && get_option( 'db_upgraded' ) ) { |
36 | 36 | flush_rewrite_rules(); |
37 | 37 | update_option( 'db_upgraded', false ); |
38 | 38 | |
… |
… |
if ( get_option('db_upgraded') ) { |
42 | 42 | * @since 2.8.0 |
43 | 43 | */ |
44 | 44 | do_action( 'after_db_upgrade' ); |
45 | | } elseif ( get_option('db_version') != $wp_db_version && empty($_POST) ) { |
| 45 | } elseif ( ! wp_doing_ajax() && |
| 46 | get_option( 'db_version' ) != $wp_db_version && |
| 47 | empty($_POST) |
| 48 | ) { |
46 | 49 | if ( !is_multisite() ) { |
47 | 50 | wp_redirect( admin_url( 'upgrade.php?_wp_http_referer=' . urlencode( wp_unslash( $_SERVER['REQUEST_URI'] ) ) ) ); |
48 | 51 | exit; |