| @@ -126,8 +126,9 @@ | ||
| 126 | 126 | */ |
| 127 | 127 | global $current_user; |
| 128 | 128 | |
| 129 | 129 | $current_wpid = (int) MainWP_System_Utility::get_current_wpid(); |
| 130 | + $is_staging = 'no'; | |
| 130 | 131 | |
| 131 | 132 | if ( $current_wpid ) { |
| 132 | 133 | $sql = MainWP_DB::instance()->get_sql_website_by_id( $current_wpid, false, array( 'wp_upgrades', 'ignored_wp_upgrades', 'ignored_trans_updates', 'premium_upgrades', 'plugins_outdate_dismissed', 'themes_outdate_dismissed', 'plugins_outdate_info', 'themes_outdate_info', 'favi_icon' ) ); |
| 133 | 134 | $globalView = false; |
| @@ -133,9 +134,8 @@ | ||
| 133 | 134 | $globalView = false; |
| 134 | 135 | } else { |
| 135 | 136 | $staging_enabled = is_plugin_active( 'mainwp-staging-extension/mainwp-staging-extension.php' ) || is_plugin_active( 'mainwp-timecapsule-extension/mainwp-timecapsule-extension.php' ); |
| 136 | 137 | // To support staging extension. |
| 137 | - $is_staging = 'no'; | |
| 138 | 138 | if ( $staging_enabled ) { |
| 139 | 139 | $staging_updates_view = MainWP_System_Utility::get_select_staging_view_sites(); |
| 140 | 140 | if ( 'staging' === $staging_updates_view ) { |
| 141 | 141 | $is_staging = 'yes'; |
| @@ -399,9 +399,9 @@ | ||
| 399 | 399 | |
| 400 | 400 | if ( ! $globalView ) { |
| 401 | 401 | $last_dtsSync = $currentSite->dtsSync; |
| 402 | 402 | } else { |
| 403 | - $result = MainWP_DB_Common::instance()->get_last_sync_status(); | |
| 403 | + $result = MainWP_DB_Common::instance()->get_last_sync_status( $is_staging ); | |
| 404 | 404 | $sync_status = $result['sync_status']; |
| 405 | 405 | $last_sync = $result['last_sync']; |
| 406 | 406 | $last_dtsSync = $result['last_sync']; |
| 407 | 407 | |