Fix floor() returning float instead of integer

This commit is contained in:
Zach Borboa
2021-07-26 00:14:52 -04:00
parent 73dfde67e2
commit 4353baa2f2
+1 -1
View File
@@ -491,7 +491,7 @@ class Curl
}
$this->httpStatusCode = $this->getInfo(CURLINFO_HTTP_CODE);
$this->httpError = in_array(floor($this->httpStatusCode / 100), [4, 5], true);
$this->httpError = in_array((int) floor($this->httpStatusCode / 100), [4, 5], true);
$this->error = $this->curlError || $this->httpError;
$this->errorCode = $this->error ? ($this->curlError ? $this->curlErrorCode : $this->httpStatusCode) : 0;