From 661bbe5f74c7b995e850ea8da4a38a2d4b91c5d1 Mon Sep 17 00:00:00 2001 From: Mateusz Grochala Date: Mon, 2 Oct 2017 15:38:18 +0200 Subject: [PATCH] Removed body from GET requests --- src/TogglApi.php | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/src/TogglApi.php b/src/TogglApi.php index 8b78300..cb13cc0 100644 --- a/src/TogglApi.php +++ b/src/TogglApi.php @@ -420,7 +420,7 @@ public function getDashboardForWorkspace($workspaceId) */ public function getMe($related = false) { - return $this->GET('me', [], ['with_related_data' => $related]); + return $this->GET('me', ['with_related_data' => $related]); } /** @@ -868,7 +868,7 @@ public function getTimeEntries() */ public function getTimeEntriesInRange($start, $end) { - return $this->GET('time_entries', [], ['start_date' => $start, 'end_date' => $end]); + return $this->GET('time_entries', ['start_date' => $start, 'end_date' => $end]); } /** @@ -918,10 +918,10 @@ public function deleteTimeEntry($timeEntryId) * * @return bool|mixed|object */ - private function GET($endpoint, $body = array(), $query = array()) + private function GET($endpoint, $query = array()) { try { - $response = $this->client->get($endpoint, ['body' => json_encode($body), 'query' => $query]); + $response = $this->client->get($endpoint, ['query' => $query]); return $this->checkResponse($response); } catch (ClientException $e) {