Skip to content
This repository has been archived by the owner on Jan 21, 2020. It is now read-only.

Commit

Permalink
Error view fix - exception could be \Exception or \Error instance
Browse files Browse the repository at this point in the history
  • Loading branch information
michalbundyra committed Aug 15, 2016
1 parent 99ebfb8 commit 71b04a7
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 2 deletions.
3 changes: 2 additions & 1 deletion module/Application/view/error/404.phtml
Original file line number Diff line number Diff line change
Expand Up @@ -52,7 +52,8 @@ if (! empty($this->reason)) :

<?php if (! empty($this->display_exceptions)) : ?>

<?php if (isset($this->exception) && $this->exception instanceof Exception) : ?>
<?php if (isset($this->exception)
&& ($this->exception instanceof \Exception || $this->exception instanceof \Error)) : ?>
<hr/>
<h2>Additional information:</h2>
<h3><?= get_class($this->exception) ?></h3>
Expand Down
3 changes: 2 additions & 1 deletion module/Application/view/error/index.phtml
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,8 @@

<?php if (! empty($this->display_exceptions)) : ?>

<?php if (isset($this->exception) && $this->exception instanceof Exception) : ?>
<?php if (isset($this->exception)
&& ($this->exception instanceof \Exception || $this->exception instanceof \Error)) : ?>
<hr/>
<h2>Additional information:</h2>
<h3><?= get_class($this->exception) ?></h3>
Expand Down

0 comments on commit 71b04a7

Please sign in to comment.