Skip to content

Commit

Permalink
Merge pull request #83 from BBrunekreeft/BBrunekreeft-invoke-descripr…
Browse files Browse the repository at this point in the history
…ion-in-error-message

Invoke error description in thrown error message.
  • Loading branch information
firstred committed Dec 10, 2023
2 parents 91748ef + 39f6b0b commit 97cb6bc
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions src/Exception/CifException.php
Original file line number Diff line number Diff line change
Expand Up @@ -60,6 +60,9 @@ public function __construct($message = '', int $code = 0, \Throwable $previous =
$this->messages = $message;

$message = $this->messages[0]['message'];
if (!empty($this->messages[0]['description'])) {
$message .= ' (' . $this->messages[0]['description'] . ')';
}
$code = $this->messages[0]['code'];
}

Expand Down

0 comments on commit 97cb6bc

Please sign in to comment.