mirror of
https://github.com/penpot/penpot.git
synced 2026-09-13 23:48:42 +00:00
✨ Improve error stack trace reporting.
This commit is contained in:
parent
433d8cee9a
commit
449ca770c1
@ -48,10 +48,13 @@
|
|||||||
|
|
||||||
(defmethod handle-exception :default
|
(defmethod handle-exception :default
|
||||||
[err req]
|
[err req]
|
||||||
(log/error err "Unhandled exception on request:" (:path req))
|
(log/error "Unhandled exception on request:" (:path req) "\n"
|
||||||
|
(with-out-str
|
||||||
|
(.printStackTrace err (java.io.PrintWriter. *out*))))
|
||||||
{:status 500
|
{:status 500
|
||||||
:body {:type :exception
|
:body {:type :exception
|
||||||
:message (ex-message err)}})
|
:message (ex-message err)
|
||||||
|
:data (ex-data err)}})
|
||||||
|
|
||||||
(defn handle
|
(defn handle
|
||||||
[error req]
|
[error req]
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user