Skip to content
This repository has been archived by the owner on Oct 27, 2022. It is now read-only.

Commit

Permalink
Merge pull request #28 from jonasdekeukelaere/fix-curl-error
Browse files Browse the repository at this point in the history
Fix error checking for curl calls
  • Loading branch information
tijsverkoyen authored May 4, 2022
2 parents 5c53fd0 + 81da609 commit 1c0d47d
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion Factr.php
Original file line number Diff line number Diff line change
Expand Up @@ -222,7 +222,7 @@ private function doCall($url, array $parameters = null, $method = 'GET', $return
}

// error?
if($errorNumber != '') throw new Exception($errorMessage, $errorNumber);
if($errorNumber !== 0) throw new Exception($errorMessage, $errorNumber);

// return the headers if needed
if($returnHeaders) return $headers;
Expand Down

0 comments on commit 1c0d47d

Please sign in to comment.