Changeset 3112499
- Timestamp:
- 07/04/2024 12:40:49 PM (21 months ago)
- Location:
- all-in-one-wp-migration/trunk
- Files:
-
- 16 edited
-
all-in-one-wp-migration.php (modified) (1 diff)
-
constants.php (modified) (1 diff)
-
lib/controller/class-ai1wm-export-controller.php (modified) (1 diff)
-
lib/controller/class-ai1wm-import-controller.php (modified) (1 diff)
-
lib/controller/class-ai1wm-main-controller.php (modified) (2 diffs)
-
lib/model/class-ai1wm-backups.php (modified) (1 diff)
-
lib/model/class-ai1wm-extensions.php (modified) (19 diffs)
-
lib/model/export/class-ai1wm-export-archive.php (modified) (1 diff)
-
lib/model/export/class-ai1wm-export-clean.php (modified) (1 diff)
-
lib/model/export/class-ai1wm-export-download.php (modified) (1 diff)
-
lib/model/import/class-ai1wm-import-clean.php (modified) (1 diff)
-
lib/model/import/class-ai1wm-import-compatibility.php (modified) (1 diff)
-
lib/view/assets/javascript/backups.min.js (modified) (3 diffs)
-
lib/view/assets/javascript/export.min.js (modified) (1 diff)
-
lib/view/assets/javascript/import.min.js (modified) (1 diff)
-
readme.txt (modified) (3 diffs)
Legend:
- Unmodified
- Added
- Removed
-
all-in-one-wp-migration/trunk/all-in-one-wp-migration.php
r3099274 r3112499 6 6 * Author: ServMask 7 7 * Author URI: https://servmask.com/ 8 * Version: 7.8 38 * Version: 7.84 9 9 * Text Domain: all-in-one-wp-migration 10 10 * Domain Path: /languages -
all-in-one-wp-migration/trunk/constants.php
r3099274 r3112499 36 36 // = Plugin Version = 37 37 // ================== 38 define( 'AI1WM_VERSION', '7.8 3' );38 define( 'AI1WM_VERSION', '7.84' ); 39 39 40 40 // =============== -
all-in-one-wp-migration/trunk/lib/controller/class-ai1wm-export-controller.php
r3038703 r3112499 74 74 75 75 } catch ( Ai1wm_Database_Exception $e ) { 76 do_action( 'ai1wm_status_export_error', $params, $e ); 77 76 78 if ( defined( 'WP_CLI' ) ) { 77 79 WP_CLI::error( sprintf( __( 'Unable to export. Error code: %s. %s', AI1WM_PLUGIN_NAME ), $e->getCode(), $e->getMessage() ) ); 78 } else {79 status_header( $e->getCode() );80 ai1wm_json_response( array( 'errors' => array( array( 'code' => $e->getCode(), 'message' => $e->getMessage() ) ) ) );81 80 } 82 Ai1wm_Directory::delete( ai1wm_storage_path( $params ) ); 83 84 // Check if export is performed from scheduled event 85 if ( isset( $params['event_id'] ) ) { 86 $params['error_message'] = $e->getMessage(); 87 do_action( 'ai1wm_status_export_fail', $params ); 88 } 81 82 status_header( $e->getCode() ); 83 ai1wm_json_response( array( 'errors' => array( array( 'code' => $e->getCode(), 'message' => $e->getMessage() ) ) ) ); 89 84 exit; 90 85 } catch ( Exception $e ) { 86 do_action( 'ai1wm_status_export_error', $params, $e ); 87 91 88 if ( defined( 'WP_CLI' ) ) { 92 89 WP_CLI::error( sprintf( __( 'Unable to export: %s', AI1WM_PLUGIN_NAME ), $e->getMessage() ) ); 93 } else {94 Ai1wm_Status::error( __( 'Unable to export', AI1WM_PLUGIN_NAME ), $e->getMessage() );95 Ai1wm_Notification::error( __( 'Unable to export', AI1WM_PLUGIN_NAME ), $e->getMessage() );96 90 } 97 Ai1wm_Directory::delete( ai1wm_storage_path( $params ) ); 98 99 // Check if export is performed from scheduled event 100 if ( isset( $params['event_id'] ) ) { 101 $params['error_message'] = $e->getMessage(); 102 do_action( 'ai1wm_status_export_fail', $params ); 103 } 91 92 Ai1wm_Status::error( __( 'Unable to export', AI1WM_PLUGIN_NAME ), $e->getMessage() ); 93 Ai1wm_Notification::error( __( 'Unable to export', AI1WM_PLUGIN_NAME ), $e->getMessage() ); 104 94 exit; 105 95 } -
all-in-one-wp-migration/trunk/lib/controller/class-ai1wm-import-controller.php
r3038703 r3112499 74 74 75 75 } catch ( Ai1wm_Import_Retry_Exception $e ) { 76 do_action( 'ai1wm_status_import_error', $params, $e ); 77 76 78 if ( defined( 'WP_CLI' ) ) { 77 79 WP_CLI::error( sprintf( __( 'Unable to import. Error code: %s. %s', AI1WM_PLUGIN_NAME ), $e->getCode(), $e->getMessage() ) ); 78 } else {79 status_header( $e->getCode() ); 80 ai1wm_json_response( array( 'errors' => array( array( 'code' => $e->getCode(), 'message' => $e->getMessage() ) )) );81 }80 } 81 82 status_header( $e->getCode() ); 83 ai1wm_json_response( array( 'errors' => array( array( 'code' => $e->getCode(), 'message' => $e->getMessage() ) ) ) ); 82 84 exit; 83 85 } catch ( Ai1wm_Database_Exception $e ) { 86 do_action( 'ai1wm_status_import_error', $params, $e ); 87 84 88 if ( defined( 'WP_CLI' ) ) { 85 89 WP_CLI::error( sprintf( __( 'Unable to import. Error code: %s. %s', AI1WM_PLUGIN_NAME ), $e->getCode(), $e->getMessage() ) ); 86 } else {87 status_header( $e->getCode() ); 88 ai1wm_json_response( array( 'errors' => array( array( 'code' => $e->getCode(), 'message' => $e->getMessage() ) )) );89 }90 Ai1wm_Directory::delete( ai1wm_storage_path( $params ) ); 90 } 91 92 status_header( $e->getCode() ); 93 ai1wm_json_response( array( 'errors' => array( array( 'code' => $e->getCode(), 'message' => $e->getMessage() ) ) ) ); 94 91 95 exit; 92 96 } catch ( Exception $e ) { 97 do_action( 'ai1wm_status_import_error', $params, $e ); 98 93 99 if ( defined( 'WP_CLI' ) ) { 94 100 WP_CLI::error( sprintf( __( 'Unable to import: %s', AI1WM_PLUGIN_NAME ), $e->getMessage() ) ); 95 } else {96 Ai1wm_Status::error( __( 'Unable to import', AI1WM_PLUGIN_NAME ), $e->getMessage() ); 97 Ai1wm_Notification::error( __( 'Unable to import', AI1WM_PLUGIN_NAME ), $e->getMessage() );98 }99 Ai1wm_Directory::delete( ai1wm_storage_path( $params ) ); 101 } 102 103 Ai1wm_Status::error( __( 'Unable to import', AI1WM_PLUGIN_NAME ), $e->getMessage() ); 104 Ai1wm_Notification::error( __( 'Unable to import', AI1WM_PLUGIN_NAME ), $e->getMessage() ); 105 100 106 exit; 101 107 } -
all-in-one-wp-migration/trunk/lib/controller/class-ai1wm-main-controller.php
r3099274 r3112499 135 135 // Enqueue updater scripts and styles 136 136 add_action( 'admin_enqueue_scripts', array( $this, 'enqueue_updater_scripts_and_styles' ), 5 ); 137 138 // Handle export/import exceptions (errors) 139 add_action( 'ai1wm_status_export_error', array( $this, 'handle_error_cleanup' ), 5, 2 ); 140 add_action( 'ai1wm_status_import_error', array( $this, 'handle_error_cleanup' ), 5, 2 ); 137 141 } 138 142 … … 1374 1378 return $schedules; 1375 1379 } 1380 1381 /** 1382 * Handles ai1wm_status_export_error hook 1383 * 1384 * @param $params 1385 * @param $exception 1386 * 1387 * @return void 1388 */ 1389 public function handle_error_cleanup( $params, $exception = null ) { 1390 if ( ! $exception instanceof Ai1wm_Import_Retry_Exception ) { 1391 Ai1wm_Directory::delete( ai1wm_storage_path( $params ) ); 1392 } 1393 } 1376 1394 } -
all-in-one-wp-migration/trunk/lib/model/class-ai1wm-backups.php
r3099274 r3112499 103 103 public static function delete_file( $file ) { 104 104 if ( ai1wm_is_filename_supported( $file ) ) { 105 return @unlink( ai1wm_backup_path( array( 'archive' => $file ) ) ); 105 if ( $deleted = @unlink( ai1wm_backup_path( array( 'archive' => $file ) ) ) ) { 106 do_action( 'ai1wm_status_backup_deleted', $file ); 107 } 108 109 return $deleted; 106 110 } 111 112 return false; 107 113 } 108 114 -
all-in-one-wp-migration/trunk/lib/model/class-ai1wm-extensions.php
r3045858 r3112499 47 47 'basename' => AI1WMZE_PLUGIN_BASENAME, 48 48 'version' => AI1WMZE_VERSION, 49 'requires' => '1.4 1',49 'requires' => '1.45', 50 50 'short' => AI1WMZE_PLUGIN_SHORT, 51 51 ); … … 61 61 'basename' => AI1WMAE_PLUGIN_BASENAME, 62 62 'version' => AI1WMAE_VERSION, 63 'requires' => '1. 46',63 'requires' => '1.50', 64 64 'short' => AI1WMAE_PLUGIN_SHORT, 65 65 ); … … 89 89 'basename' => AI1WMBE_PLUGIN_BASENAME, 90 90 'version' => AI1WMBE_VERSION, 91 'requires' => '1. 57',91 'requires' => '1.61', 92 92 'short' => AI1WMBE_PLUGIN_SHORT, 93 93 ); … … 103 103 'basename' => AI1WMIE_PLUGIN_BASENAME, 104 104 'version' => AI1WMIE_VERSION, 105 'requires' => '1. 57',105 'requires' => '1.61', 106 106 'short' => AI1WMIE_PLUGIN_SHORT, 107 107 ); … … 117 117 'basename' => AI1WMXE_PLUGIN_BASENAME, 118 118 'version' => AI1WMXE_VERSION, 119 'requires' => '1. 26',119 'requires' => '1.30', 120 120 'short' => AI1WMXE_PLUGIN_SHORT, 121 121 ); … … 131 131 'basename' => AI1WMDE_PLUGIN_BASENAME, 132 132 'version' => AI1WMDE_VERSION, 133 'requires' => '3.8 1',133 'requires' => '3.85', 134 134 'short' => AI1WMDE_PLUGIN_SHORT, 135 135 ); … … 159 159 'basename' => AI1WMFE_PLUGIN_BASENAME, 160 160 'version' => AI1WMFE_VERSION, 161 'requires' => '2.8 0',161 'requires' => '2.84', 162 162 'short' => AI1WMFE_PLUGIN_SHORT, 163 163 ); … … 173 173 'basename' => AI1WMCE_PLUGIN_BASENAME, 174 174 'version' => AI1WMCE_VERSION, 175 'requires' => '1. 49',175 'requires' => '1.53', 176 176 'short' => AI1WMCE_PLUGIN_SHORT, 177 177 ); … … 187 187 'basename' => AI1WMGE_PLUGIN_BASENAME, 188 188 'version' => AI1WMGE_VERSION, 189 'requires' => '2.8 5',189 'requires' => '2.89', 190 190 'short' => AI1WMGE_PLUGIN_SHORT, 191 191 ); … … 201 201 'basename' => AI1WMRE_PLUGIN_BASENAME, 202 202 'version' => AI1WMRE_VERSION, 203 'requires' => '1.4 3',203 'requires' => '1.47', 204 204 'short' => AI1WMRE_PLUGIN_SHORT, 205 205 ); … … 215 215 'basename' => AI1WMEE_PLUGIN_BASENAME, 216 216 'version' => AI1WMEE_VERSION, 217 'requires' => '1.5 0',217 'requires' => '1.54', 218 218 'short' => AI1WMEE_PLUGIN_SHORT, 219 219 ); … … 229 229 'basename' => AI1WMME_PLUGIN_BASENAME, 230 230 'version' => AI1WMME_VERSION, 231 'requires' => '4.3 3',231 'requires' => '4.37', 232 232 'short' => AI1WMME_PLUGIN_SHORT, 233 233 ); … … 243 243 'basename' => AI1WMOE_PLUGIN_BASENAME, 244 244 'version' => AI1WMOE_VERSION, 245 'requires' => '1.7 0',245 'requires' => '1.74', 246 246 'short' => AI1WMOE_PLUGIN_SHORT, 247 247 ); … … 257 257 'basename' => AI1WMPE_PLUGIN_BASENAME, 258 258 'version' => AI1WMPE_VERSION, 259 'requires' => '1.4 4',259 'requires' => '1.48', 260 260 'short' => AI1WMPE_PLUGIN_SHORT, 261 261 ); … … 285 285 'basename' => AI1WMNE_PLUGIN_BASENAME, 286 286 'version' => AI1WMNE_VERSION, 287 'requires' => '1.4 1',287 'requires' => '1.45', 288 288 'short' => AI1WMNE_PLUGIN_SHORT, 289 289 ); … … 299 299 'basename' => AI1WMSE_PLUGIN_BASENAME, 300 300 'version' => AI1WMSE_VERSION, 301 'requires' => '3.8 1',301 'requires' => '3.85', 302 302 'short' => AI1WMSE_PLUGIN_SHORT, 303 303 ); … … 313 313 'basename' => AI1WMUE_PLUGIN_BASENAME, 314 314 'version' => AI1WMUE_VERSION, 315 'requires' => '2.5 5',315 'requires' => '2.59', 316 316 'short' => AI1WMUE_PLUGIN_SHORT, 317 317 ); … … 327 327 'basename' => AI1WMLE_PLUGIN_BASENAME, 328 328 'version' => AI1WMLE_VERSION, 329 'requires' => '2. 67',329 'requires' => '2.71', 330 330 'short' => AI1WMLE_PLUGIN_SHORT, 331 331 ); … … 341 341 'basename' => AI1WMWE_PLUGIN_BASENAME, 342 342 'version' => AI1WMWE_VERSION, 343 'requires' => '1. 38',343 'requires' => '1.42', 344 344 'short' => AI1WMWE_PLUGIN_SHORT, 345 345 ); -
all-in-one-wp-migration/trunk/lib/model/export/class-ai1wm-export-archive.php
r3038703 r3112499 32 32 public static function execute( $params ) { 33 33 34 do_action( 'ai1wm_status_export_start', $params ); 35 34 36 // Set progress 35 37 Ai1wm_Status::info( __( 'Creating an empty archive...', AI1WM_PLUGIN_NAME ) ); -
all-in-one-wp-migration/trunk/lib/model/export/class-ai1wm-export-clean.php
r3038703 r3112499 35 35 Ai1wm_Directory::delete( ai1wm_storage_path( $params ) ); 36 36 37 if ( isset( $params['ai1wm_export_cancel'] ) ) { 38 do_action( 'ai1wm_status_export_canceled', $params ); 39 } 40 37 41 // Exit in console 38 42 if ( defined( 'WP_CLI' ) ) { -
all-in-one-wp-migration/trunk/lib/model/export/class-ai1wm-export-download.php
r3099274 r3112499 98 98 do_action( 'ai1wm_status_export_done', $params ); 99 99 100 if ( isset( $params['ai1wm_manual_backup'] ) ) { 101 do_action( 'ai1wm_status_backup_created', $params ); 102 } 103 100 104 return $params; 101 105 } -
all-in-one-wp-migration/trunk/lib/model/import/class-ai1wm-import-clean.php
r3089446 r3112499 38 38 $db_client->flush(); 39 39 40 if ( isset( $params['ai1wm_import_cancel'] ) ) { 41 do_action( 'ai1wm_status_import_canceled', $params ); 42 } else { 43 do_action( 'ai1wm_status_import_done', $params ); 44 } 45 40 46 // Delete storage files 41 47 Ai1wm_Directory::delete( ai1wm_storage_path( $params ) ); -
all-in-one-wp-migration/trunk/lib/model/import/class-ai1wm-import-compatibility.php
r3038703 r3112499 31 31 32 32 public static function execute( $params ) { 33 do_action( 'ai1wm_status_import_start', $params ); 33 34 34 35 // Set progress -
all-in-one-wp-migration/trunk/lib/view/assets/javascript/backups.min.js
r3099274 r3112499 249 249 name: 'priority', 250 250 value: 300 251 }).concat({ 252 name: 'ai1wm_export_cancel', 253 value: 1 251 254 }); // Set additional params 252 255 … … 627 630 628 631 this.modal.onStop = function (options) { 632 options = (options || []).concat({ 633 name: 'ai1wm_import_cancel', 634 value: 1 635 }); 629 636 self.onStop(options); 630 637 }; // Set disk space listener … … 2862 2869 name: 'file', 2863 2870 value: 1 2871 }).concat({ 2872 name: 'ai1wm_manual_backup', 2873 value: 1 2864 2874 }); // Set global params 2865 2875 -
all-in-one-wp-migration/trunk/lib/view/assets/javascript/export.min.js
r3099274 r3112499 209 209 name: 'priority', 210 210 value: 300 211 }).concat({ 212 name: 'ai1wm_export_cancel', 213 value: 1 211 214 }); // Set additional params 212 215 -
all-in-one-wp-migration/trunk/lib/view/assets/javascript/import.min.js
r3038703 r3112499 49 49 50 50 this.modal.onStop = function (options) { 51 options = (options || []).concat({ 52 name: 'ai1wm_import_cancel', 53 value: 1 54 }); 51 55 self.onStop(options); 52 56 }; // Set disk space listener -
all-in-one-wp-migration/trunk/readme.txt
r3099274 r3112499 3 3 Tags: backup, transfer, copy, move, clone 4 4 Requires at least: 3.3 5 Tested up to: 6. 55 Tested up to: 6.6 6 6 Requires PHP: 5.3 7 Stable tag: 7.8 37 Stable tag: 7.84 8 8 License: GPLv2 or later 9 9 … … 25 25 One feature that makes All-in-One WP Migration widely loved (to the tune of over 6,000 5-star user reviews) is that the technical requirements for installing the plugin are simple. 26 26 27 If you have WordPress version between 3.3 and 6.5. 4and PHP version between 5.3 and 8.3, you are good to go. All-in-One WP Migration also supports all versions of MySQL, MariaDB and SQLite.27 If you have WordPress version between 3.3 and 6.5.5 and PHP version between 5.3 and 8.3, you are good to go. All-in-One WP Migration also supports all versions of MySQL, MariaDB and SQLite. 28 28 29 29 **Features Spotlight:** … … 98 98 99 99 == Changelog == 100 = 7.84 = 101 **Added** 102 103 * New hooks during the export and import processes to allow for custom actions and integrations 104 100 105 = 7.83 = 101 106 **Fixed**
Note: See TracChangeset
for help on using the changeset viewer.