Skip to content

Commit d2f4f0b

Browse files
authored
Update AsanaCurl.php
Fixed: Big ints get parsed to a float in json_decode. JSON_BIGINT_AS_STRING
1 parent 6f6cffa commit d2f4f0b

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

src/Torann/LaravelAsana/AsanaCurl.php

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -165,7 +165,7 @@ private function request($method, $url, $data = null)
165165
// Make request
166166
try {
167167
$response = curl_exec($this->curl);
168-
$response = json_decode($response);
168+
$response = json_decode($response, false, 512, JSON_BIGINT_AS_STRING);
169169
} catch (Exception $e) {
170170
$this->errors = [$e->getMessage()];
171171
$response = null;
@@ -274,4 +274,4 @@ private function checkForCurlErrors($response)
274274
throw new Exception(curl_error($this->curl), curl_errno($this->curl));
275275
}
276276
}
277-
}
277+
}

0 commit comments

Comments
 (0)