Skip to content

Commit

Permalink
Update ChainException to support Throwables
Browse files Browse the repository at this point in the history
Fixes issue where TypeErrors, etc, would cause an exception without the relevant messages shown
  • Loading branch information
predakanga authored Aug 22, 2020
1 parent 13b25dc commit 0ef63e5
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/Exception/ChainException.php
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@ final class ChainException extends Exception
*/
public function __construct(array $exceptions)
{
$messages = array_map(function (\Exception $exception) {
$messages = array_map(function (\Throwable $exception) {
return sprintf(
'%s: %s',
get_class($exception),
Expand Down

0 comments on commit 0ef63e5

Please sign in to comment.