| @@ -4,8 +4,9 @@ | ||
| 4 | 4 | $args = ['body' => $body, 'timeout' => '5', 'redirection' => '5', 'httpversion' => '1.0', 'blocking' => true, 'headers' => $header, 'cookies' => []]; |
| 5 | 5 | $response = wp_remote_post($apiUrl, $args); |
| 6 | 6 | if ($breakResponse) |
| 7 | 7 | __tagembed__dd($response); |
| 8 | + | |
| 8 | 9 | if (!is_wp_error($response)): |
| 9 | 10 | if (isset($response['body']) && !empty($response['body'])) |
| 10 | 11 | return json_decode($response['body']); |
| 11 | 12 | return; |