@@ 4459-4469 (lines=11) @@ | ||
4456 | self::activate_default_modules( $min_version, $max_version, $other_modules ); |
|
4457 | wp_safe_redirect( self::admin_url( 'page=jetpack' ) ); |
|
4458 | exit; |
|
4459 | case 'disconnect': |
|
4460 | if ( ! current_user_can( 'jetpack_disconnect' ) ) { |
|
4461 | $error = 'cheatin'; |
|
4462 | break; |
|
4463 | } |
|
4464 | ||
4465 | check_admin_referer( 'jetpack-disconnect' ); |
|
4466 | self::log( 'disconnect' ); |
|
4467 | self::disconnect(); |
|
4468 | wp_safe_redirect( self::admin_url( 'disconnected=true' ) ); |
|
4469 | exit; |
|
4470 | case 'reconnect': |
|
4471 | if ( ! current_user_can( 'jetpack_reconnect' ) ) { |
|
4472 | $error = 'cheatin'; |
|
@@ 4470-4480 (lines=11) @@ | ||
4467 | self::disconnect(); |
|
4468 | wp_safe_redirect( self::admin_url( 'disconnected=true' ) ); |
|
4469 | exit; |
|
4470 | case 'reconnect': |
|
4471 | if ( ! current_user_can( 'jetpack_reconnect' ) ) { |
|
4472 | $error = 'cheatin'; |
|
4473 | break; |
|
4474 | } |
|
4475 | ||
4476 | check_admin_referer( 'jetpack-reconnect' ); |
|
4477 | self::log( 'reconnect' ); |
|
4478 | self::disconnect(); |
|
4479 | wp_redirect( $this->build_connect_url( true, false, 'reconnect' ) ); |
|
4480 | exit; |
|
4481 | case 'deactivate': |
|
4482 | if ( ! current_user_can( 'jetpack_deactivate_modules' ) ) { |
|
4483 | $error = 'cheatin'; |