yii\web\ErrorHandler::renderPreviousExceptions PHP Method

renderPreviousExceptions() public method

Renders the previous exception stack for a given Exception.
public renderPreviousExceptions ( Exception $exception ) : string
$exception Exception the exception whose precursors should be rendered.
return string HTML content of the rendered previous exceptions. Empty string if there are none.
    public function renderPreviousExceptions($exception)
    {
        if (($previous = $exception->getPrevious()) !== null) {
            return $this->renderFile($this->previousExceptionView, ['exception' => $previous]);
        } else {
            return '';
        }
    }