From 7974a8f9e074232089774329ec51574ee17e158d Mon Sep 17 00:00:00 2001 From: Gareth Nicholson Date: Thu, 18 Feb 2021 14:55:20 +0200 Subject: [PATCH] Minor adjustments. --- src/ClickatellClient.php | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/src/ClickatellClient.php b/src/ClickatellClient.php index 869a494..933d942 100644 --- a/src/ClickatellClient.php +++ b/src/ClickatellClient.php @@ -38,17 +38,17 @@ public function __construct(Client $client, $apiKey) */ public function send(array $to, $message) { - $to = collect($to)->toArray(); - $response = $this->client->request('GET', 'https://platform.clickatell.com/messages/http/send', [ 'query' => [ 'apiKey' => $this->apiKey, 'to' => $to, 'content' => $message, ], - ])->getBody(); + ])->getBody()->getContents; + + $response = json_decode($response, true); - $this->handleProviderResponses($response); + return $this->handleProviderResponses($response); } /**