class.jetpack-plan.php 1 location
|
@@ 35-37 (lines=3) @@
|
32 |
|
*/ |
33 |
|
public static function update_from_sites_response( $response ) { |
34 |
|
// Bail if there was an error or malformed response. |
35 |
|
if ( is_wp_error( $response ) || ! is_array( $response ) || ! isset( $response['body'] ) ) { |
36 |
|
return false; |
37 |
|
} |
38 |
|
|
39 |
|
$body = wp_remote_retrieve_body( $response ); |
40 |
|
if ( is_wp_error( $body ) ) { |
packages/purchases/src/class-purchases.php 1 location
|
@@ 48-50 (lines=3) @@
|
45 |
|
$response = Client::wpcom_json_api_request_as_blog( $request, '1.1', array( 'owner' => 'site' ) ); |
46 |
|
|
47 |
|
// Bail if there was an error or malformed response. |
48 |
|
if ( is_wp_error( $response ) || ! is_array( $response ) || ! isset( $response['body'] ) ) { |
49 |
|
return false; |
50 |
|
} |
51 |
|
|
52 |
|
$body = wp_remote_retrieve_body( $response ); |
53 |
|
if ( is_wp_error( $body ) ) { |