mirror of
https://github.com/slawkens/myaac.git
synced 2025-04-26 09:19:22 +02:00
Add exception class to whoops screen
This commit is contained in:
parent
1427dc3ede
commit
a5ccc794bc
@ -39,7 +39,7 @@ function exception_handler($exception) {
|
||||
// we just replace some values manually
|
||||
// cause in case Twig throws exception, we can show it too
|
||||
$content = file_get_contents($template_file);
|
||||
$content = str_replace(array('{{ BASE_URL }}', '{{ message }}', '{{ backtrace }}', '{{ powered_by }}'), array(BASE_URL, $message, $backtrace_formatted, base64_decode('UG93ZXJlZCBieSA8YSBocmVmPSJodHRwOi8vbXktYWFjLm9yZyIgdGFyZ2V0PSJfYmxhbmsiPk15QUFDLjwvYT4=')), $content);
|
||||
$content = str_replace(array('{{ BASE_URL }}', '{{ exceptionClass }}', '{{ message }}', '{{ backtrace }}', '{{ powered_by }}'), array(BASE_URL, get_class($exception), $message, $backtrace_formatted, base64_decode('UG93ZXJlZCBieSA8YSBocmVmPSJodHRwOi8vbXktYWFjLm9yZyIgdGFyZ2V0PSJfYmxhbmsiPk15QUFDLjwvYT4=')), $content);
|
||||
|
||||
echo $content;
|
||||
}
|
||||
|
@ -64,6 +64,8 @@
|
||||
<div class="center wide">
|
||||
<h2 class="wide">Whoops something went wrong...</h2>
|
||||
<div class="error wide">
|
||||
Exception class: {{ exceptionClass }}()
|
||||
<br/><br/>
|
||||
{{ message }}
|
||||
<br/><br/><br/>
|
||||
<b>Backtrace:</b><br/><br/>
|
||||
@ -74,4 +76,4 @@
|
||||
<p>{{ powered_by }}</p>
|
||||
</div>
|
||||
</body>
|
||||
</html>
|
||||
</html>
|
||||
|
Loading…
x
Reference in New Issue
Block a user