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