Skip to content

Commit

Permalink
#37 Exeption title fix
Browse files Browse the repository at this point in the history
  • Loading branch information
Vitexus committed Jan 17, 2024
1 parent d4bd5fe commit 53daef9
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/AbraFlexi/RO.php
Expand Up @@ -1230,7 +1230,7 @@ public function parseResponse($responseDecoded, $responseCode)
}
if ($this->throwException) {
$errors = $this->getErrors();
throw new Exception(empty($errors) ? 'Problem ' : $errors[0]['message'], $this);
throw new Exception(empty($errors) ? 'Problem ' : (is_array($errors[0]) ? $errors[0]['message'] : $errors[0] ), $this);
} else {
$this->addStatusMessage($this->lastResponseCode . ': ' . $this->curlInfo['url'] . ' (' . $this->format . ') ' . json_encode($this->getErrors()), 'warning');
}
Expand Down

0 comments on commit 53daef9

Please sign in to comment.