Code Duplication    Length = 3-3 lines in 2 locations

includes/api/class-wc-rest-system-status-controller.php 2 locations

@@ 461-463 (lines=3) @@
458
			)
459
		) );
460
		$post_response_successful = false;
461
		if ( ! is_wp_error( $post_response ) && $post_response['response']['code'] >= 200 && $post_response['response']['code'] < 300 ) {
462
			$post_response_successful = true;
463
		}
464
465
		// Test GET requests
466
		$get_response = wp_safe_remote_get( 'https://woocommerce.com/wc-api/product-key-api?request=ping&network=' . ( is_multisite() ? '1' : '0' ) );
@@ 468-470 (lines=3) @@
465
		// Test GET requests
466
		$get_response = wp_safe_remote_get( 'https://woocommerce.com/wc-api/product-key-api?request=ping&network=' . ( is_multisite() ? '1' : '0' ) );
467
		$get_response_successful = false;
468
		if ( ! is_wp_error( $post_response ) && $post_response['response']['code'] >= 200 && $post_response['response']['code'] < 300 ) {
469
			$get_response_successful = true;
470
		}
471
472
		// Return all environment info. Described by JSON Schema.
473
		return array(