SiteGround Migrator - Version 2.0.3

Version Description

Download this release

Release Info

Developer elenachavdarova
Plugin Icon 128x128 SiteGround Migrator
Version 2.0.3
Comparing to
See all releases

Code changes from version 2.0.2 to 2.0.3

README.txt CHANGED
@@ -4,7 +4,7 @@ License: GPLv3
4
  License URI: http://www.gnu.org/licenses/gpl.html
5
  Tags: Transfer, Migration, SiteGround, automatic transfer, automatic migration
6
  Requires at least: 4.8
7
- Tested up to: 6.0
8
  Requires PHP: 5.6.0
9
 
10
  Transfer your WordPress website to SiteGround without any hassle in a completely automated way using SiteGround Migrator.
@@ -46,6 +46,12 @@ In version 1.0.13 we've added WP-CLI command for migrations.
46
 
47
  == Changelog ==
48
 
 
 
 
 
 
 
49
  = Version 2.0.2 =
50
  Release Date: Oct 6th, 2022
51
 
4
  License URI: http://www.gnu.org/licenses/gpl.html
5
  Tags: Transfer, Migration, SiteGround, automatic transfer, automatic migration
6
  Requires at least: 4.8
7
+ Tested up to: 6.1
8
  Requires PHP: 5.6.0
9
 
10
  Transfer your WordPress website to SiteGround without any hassle in a completely automated way using SiteGround Migrator.
46
 
47
  == Changelog ==
48
 
49
+ = Version 2.0.3 =
50
+ Release Date: Nov 1st, 2022
51
+
52
+ * Improved transfer success screen
53
+ * Improved deactivation checks
54
+
55
  = Version 2.0.2 =
56
  Release Date: Oct 6th, 2022
57
 
core/Deactivator/Deactivator.php CHANGED
@@ -3,6 +3,7 @@
3
  namespace SiteGround_Migrator\Deactivator;
4
 
5
  use SiteGround_Migrator\Directory_Service\Directory_Service;
 
6
 
7
  /**
8
  * Class managing plugin deactivation.
@@ -15,6 +16,13 @@ class Deactivator {
15
  * @since 1.0.0
16
  */
17
  public static function deactivate() {
 
 
 
 
 
 
 
18
  Directory_Service::get_instance()->remove_temp_dir();
19
 
20
  global $wpdb;
3
  namespace SiteGround_Migrator\Deactivator;
4
 
5
  use SiteGround_Migrator\Directory_Service\Directory_Service;
6
+ use SiteGround_Migrator\Transfer_Service\Transfer_Service;
7
 
8
  /**
9
  * Class managing plugin deactivation.
16
  * @since 1.0.0
17
  */
18
  public static function deactivate() {
19
+ $status = (int) get_option( 'siteground_migrator_transfer_status', false );
20
+
21
+ // Cancel and reset the transfer if is still in progress while deactivating.
22
+ if ( 1 === $status || 2 === $status ) {
23
+ Transfer_Service::get_instance()->cancel_and_reset();
24
+ }
25
+
26
  Directory_Service::get_instance()->remove_temp_dir();
27
 
28
  global $wpdb;
core/Helper/Helper.php CHANGED
@@ -161,7 +161,7 @@ class Helper {
161
  wp_remote_get( $url );
162
  }
163
 
164
- if ( 3 === $counter ) {
165
  return false;
166
  }
167
 
161
  wp_remote_get( $url );
162
  }
163
 
164
+ if ( 2 === $counter ) {
165
  return false;
166
  }
167
 
core/Rest/Rest_Helper_Transfer_Service.php CHANGED
@@ -201,7 +201,10 @@ class Rest_Helper_Transfer_Service extends Rest_Helper {
201
  ),
202
  );
203
 
204
- if ( $is_siteground ) {
 
 
 
205
  // Send the response.
206
  self::send_json_success(
207
  __( 'Transfer Completed Successfully!', 'siteground-migrator' ),
201
  ),
202
  );
203
 
204
+ if (
205
+ $is_siteground ||
206
+ ! empty( get_option( 'sg_migrator_colibri', false ) )
207
+ ) {
208
  // Send the response.
209
  self::send_json_success(
210
  __( 'Transfer Completed Successfully!', 'siteground-migrator' ),
siteground-migrator.php CHANGED
@@ -24,7 +24,7 @@ use ShuttleExport\Exporter;
24
  * Plugin Name: SiteGround Migrator
25
  * Plugin URI: http://siteground.com
26
  * Description: This plugin is designed to migrate your WordPress site to SiteGround
27
- * Version: 2.0.2
28
  * Author: SiteGround
29
  * Author URI: https://www.siteground.com
30
  * License: GPL-2.0+
@@ -40,7 +40,7 @@ if ( ! defined( 'WPINC' ) ) {
40
 
41
  // Define version constant.
42
  if ( ! defined( __NAMESPACE__ . '\VERSION' ) ) {
43
- define( __NAMESPACE__ . '\VERSION', '2.0.2' );
44
  }
45
 
46
  // Define slug constant.
24
  * Plugin Name: SiteGround Migrator
25
  * Plugin URI: http://siteground.com
26
  * Description: This plugin is designed to migrate your WordPress site to SiteGround
27
+ * Version: 2.0.3
28
  * Author: SiteGround
29
  * Author URI: https://www.siteground.com
30
  * License: GPL-2.0+
40
 
41
  // Define version constant.
42
  if ( ! defined( __NAMESPACE__ . '\VERSION' ) ) {
43
+ define( __NAMESPACE__ . '\VERSION', '2.0.3' );
44
  }
45
 
46
  // Define slug constant.