Merge pull request #22551 from princeahmed/master

Fix test get request
This commit is contained in:
Mike Jolley 2019-01-31 13:11:03 +00:00 committed by GitHub
commit f7f2b99211
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 1 additions and 1 deletions

View File

@ -602,7 +602,7 @@ class WC_REST_System_Status_V2_Controller extends WC_REST_Controller {
// Test GET requests.
$get_response = wp_safe_remote_get( 'https://woocommerce.com/wc-api/product-key-api?request=ping&network=' . ( is_multisite() ? '1' : '0' ) );
$get_response_successful = false;
if ( ! is_wp_error( $post_response ) && $post_response['response']['code'] >= 200 && $post_response['response']['code'] < 300 ) {
if ( ! is_wp_error( $get_response ) && $get_response['response']['code'] >= 200 && $get_response['response']['code'] < 300 ) {
$get_response_successful = true;
}