[#13038] Add error message to email template on crash
This commit is contained in:
parent
7bbb882ffa
commit
93d4dc8cb5
|
@ -60,4 +60,4 @@
|
||||||
{:title "Error"
|
{:title "Error"
|
||||||
:content (.-message e)
|
:content (.-message e)
|
||||||
:confirm-button-text (i18n/label :t/send-logs)
|
:confirm-button-text (i18n/label :t/send-logs)
|
||||||
:on-accept #(re-frame/dispatch [:logging.ui/send-logs-pressed :email])})))))))
|
:on-accept #(re-frame/dispatch [:logging/send-logs-on-error (.-message e)])})))))))
|
||||||
|
|
|
@ -153,6 +153,13 @@
|
||||||
::share-logs-file)]})
|
::share-logs-file)]})
|
||||||
(send-email-event cofx nil)))
|
(send-email-event cofx nil)))
|
||||||
|
|
||||||
|
(fx/defn send-logs-on-error
|
||||||
|
{:events [:logging/send-logs-on-error]}
|
||||||
|
[{:keys [db]} error-message]
|
||||||
|
(fx/merge
|
||||||
|
{:db (assoc-in db [:bug-report/details :description] error-message)}
|
||||||
|
(send-logs :email)))
|
||||||
|
|
||||||
(fx/defn show-client-error
|
(fx/defn show-client-error
|
||||||
{:events [:show-client-error]}
|
{:events [:show-client-error]}
|
||||||
[_]
|
[_]
|
||||||
|
|
Loading…
Reference in New Issue