function FlattenException::toArray
File
-
vendor/
symfony/ error-handler/ Exception/ FlattenException.php, line 115
Class
- FlattenException
- FlattenException wraps a PHP Error or Exception to be able to serialize it.
Namespace
Symfony\Component\ErrorHandler\ExceptionCode
public function toArray() : array {
$exceptions = [];
foreach (array_merge([
$this,
], $this->getAllPrevious()) as $exception) {
$exceptions[] = [
'message' => $exception->getMessage(),
'class' => $exception->getClass(),
'trace' => $exception->getTrace(),
'data' => $exception->getDataRepresentation(),
];
}
return $exceptions;
}