File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change 33/**
44 * Migrate your DB using WP Sync DB.
55 */
6- class WPSDBCLI extends WP_CLI_Command {
6+ class WPSDBCLI extends WP_CLI_Command
7+ {
78
8- /**
9- * Run a migration.
10- *
11- * ## OPTIONS
12- *
13- * <profile>
14- * : ID of the profile to use for the migration.
15- *
16- * ## EXAMPLES
17- *
18- * wp wpsdb migrate 1
19- *
20- * @synopsis <profile>
21- *
22- * @since 1.0
23- */
24- public function migrate( $args, $assoc_args ) {
25- $profile = $args[0];
9+ /**
10+ * Run a migration.
11+ *
12+ * ## OPTIONS
13+ *
14+ * <profile>
15+ * : ID of the profile to use for the migration.
16+ *
17+ * ## EXAMPLES
18+ *
19+ * wp wpsdb migrate 1
20+ *
21+ * @synopsis <profile>
22+ *
23+ * @since 1.0
24+ */
25+ public function migrate($args, $assoc_args)
26+ {
27+ $profile = $args[0];
2628
27- $result = wpsdb_migrate( $profile );
29+ $result = wpsdb_migrate($profile);
2830
29- if ( true === $result ) {
30- WP_CLI::success( __( 'Migration successful.', 'wp-sync-db-cli' ) );
31- return;
32- }
31+ if (true === $result) {
32+ WP_CLI::success(__('Migration successful.', 'wp-sync-db-cli') );
33+ return;
34+ }
3335
34- WP_CLI::warning( $result->get_error_message() );
35- return;
36- }
36+ WP_CLI::warning($result->get_error_message());
37+ return;
38+ }
3739
3840}
3941
40- WP_CLI::add_command( 'wpsdb', 'WPSDBCLI' );
42+ WP_CLI::add_command('wpsdb', 'WPSDBCLI');
You can’t perform that action at this time.
0 commit comments