Firefly III: a personal finances manager
PHP accountingbudgetbudgetingbudgetscash-flowcashflowcredit-carddockerexpensesfinancefinancesfinanciallinuxmoneypaycheckpersonal-financephpphp7
Will inform about the logged in user
James Colef1750e3c3510
diff --git a/app/Exceptions/Handler.php b/app/Exceptions/Handler.phpindex 0a5c1a01db..110ac12f83 100644--- a/app/Exceptions/Handler.php+++ b/app/Exceptions/Handler.php@@ -12,6 +12,7 @@ use Log;use Mail;use Swift_TransportException;use Symfony\Component\HttpKernel\Exception\HttpException;+use Auth;/*** Class Handler@@ -57,6 +58,8 @@ class Handler extends ExceptionHandler'file' => $exception->getFile(),'line' => $exception->getLine(),'code' => $exception->getCode(),+ 'loggedIn' => Auth::check(),+ 'user' => Auth::user(),];Mail::send(diff --git a/resources/views/emails/error-html.twig b/resources/views/emails/error-html.twigindex 9893172ec2..83d3b084ee 100644--- a/resources/views/emails/error-html.twig+++ b/resources/views/emails/error-html.twig@@ -12,6 +12,12 @@This error occured in file <span style="font-family: monospace;">{{ file }}</span> on line {{ line }} with code {{ code }}.</p>+{% if loggedIn %}+<p style="font-family: 'Helvetica Neue', Helvetica, Arial, sans-serif;font-size:13px;">+ The error was encountered by user #{{ user.id }}, <a href="mailto:{{ user.email }}">{{ user.email }}</a>.+</p>+{% endif %}+<p style="font-family: 'Helvetica Neue', Helvetica, Arial, sans-serif;font-size:13px;">The full stacktrace is below. If you think this is a bug in Firefly III, youcan forward this message todiff --git a/resources/views/emails/error.twig b/resources/views/emails/error.twigindex 03c60c67b8..28986f90a7 100644--- a/resources/views/emails/error.twig+++ b/resources/views/emails/error.twig@@ -2,6 +2,10 @@ Firefly III ran into an error: {{ errorMessage }}.This error occured in file "{{ file }}" on line {{ line }} with code {{ code }}.+{% if loggedIn %}+The error was encountered by user #{{ user.id }}, {{ user.email }}.+{% endif %}+The full stacktrace is below. If you think this is a bug in Firefly III, youcan forward this message to [email protected]. This can help fixthe bug you just encountered.