|
@@ 495-502 (lines=8) @@
|
| 492 |
|
* Done here because it's easier to read the $whitelist array after it's been rebuilt |
| 493 |
|
*/ |
| 494 |
|
if ( isset( $args[1] ) && 'list' == $args[1] ) { |
| 495 |
|
if ( ! empty( $whitelist ) ) { |
| 496 |
|
WP_CLI::success( __( 'Here are your whitelisted IPs:', 'jetpack' ) ); |
| 497 |
|
foreach ( $whitelist as $ip ) { |
| 498 |
|
WP_CLI::line( "\t" . str_pad( $ip, 24 ) ) ; |
| 499 |
|
} |
| 500 |
|
} else { |
| 501 |
|
WP_CLI::line( __( 'Whitelist is empty.', "jetpack" ) ) ; |
| 502 |
|
} |
| 503 |
|
break; |
| 504 |
|
} |
| 505 |
|
|
|
@@ 748-758 (lines=11) @@
|
| 745 |
|
} else { |
| 746 |
|
WP_CLI::log( __( 'Initialized a new full sync', 'jetpack' ) ); |
| 747 |
|
} |
| 748 |
|
} else { |
| 749 |
|
|
| 750 |
|
// Reset sync settings to original. |
| 751 |
|
Jetpack_Sync_Settings::update_settings( $original_settings ); |
| 752 |
|
|
| 753 |
|
if ( $modules ) { |
| 754 |
|
WP_CLI::error( sprintf( __( 'Could not start a new full sync with modules: %s', 'jetpack' ), join( ', ', $modules ) ) ); |
| 755 |
|
} else { |
| 756 |
|
WP_CLI::error( __( 'Could not start a new full sync', 'jetpack' ) ); |
| 757 |
|
} |
| 758 |
|
} |
| 759 |
|
|
| 760 |
|
// Keep sending to WPCOM until there's nothing to send |
| 761 |
|
$i = 1; |