@@ 4441-4451 (lines=11) @@ | ||
4438 | self::activate_default_modules( $min_version, $max_version, $other_modules ); |
|
4439 | wp_safe_redirect( self::admin_url( 'page=jetpack' ) ); |
|
4440 | exit; |
|
4441 | case 'disconnect': |
|
4442 | if ( ! current_user_can( 'jetpack_disconnect' ) ) { |
|
4443 | $error = 'cheatin'; |
|
4444 | break; |
|
4445 | } |
|
4446 | ||
4447 | check_admin_referer( 'jetpack-disconnect' ); |
|
4448 | self::log( 'disconnect' ); |
|
4449 | self::disconnect(); |
|
4450 | wp_safe_redirect( self::admin_url( 'disconnected=true' ) ); |
|
4451 | exit; |
|
4452 | case 'reconnect': |
|
4453 | if ( ! current_user_can( 'jetpack_reconnect' ) ) { |
|
4454 | $error = 'cheatin'; |
|
@@ 4452-4462 (lines=11) @@ | ||
4449 | self::disconnect(); |
|
4450 | wp_safe_redirect( self::admin_url( 'disconnected=true' ) ); |
|
4451 | exit; |
|
4452 | case 'reconnect': |
|
4453 | if ( ! current_user_can( 'jetpack_reconnect' ) ) { |
|
4454 | $error = 'cheatin'; |
|
4455 | break; |
|
4456 | } |
|
4457 | ||
4458 | check_admin_referer( 'jetpack-reconnect' ); |
|
4459 | self::log( 'reconnect' ); |
|
4460 | self::disconnect(); |
|
4461 | wp_redirect( $this->build_connect_url( true, false, 'reconnect' ) ); |
|
4462 | exit; |
|
4463 | case 'deactivate': |
|
4464 | if ( ! current_user_can( 'jetpack_deactivate_modules' ) ) { |
|
4465 | $error = 'cheatin'; |