Skip to content

Commit 18464ef

Browse files
committed
enhance: catch error when thread-api throws (2)
1 parent 11e6eaf commit 18464ef

File tree

1 file changed

+3
-2
lines changed

1 file changed

+3
-2
lines changed

src/main/frontend/common/thread_api.cljc

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,8 @@
22
"Macro for defining thread apis, which is invokeable by other threads"
33
#?(:cljs (:require-macros [frontend.common.thread-api]))
44
#?(:cljs (:require [logseq.db :as ldb]
5-
[promesa.core :as p])))
5+
[promesa.core :as p]
6+
[lambdaisland.glogi :as log])))
67

78
#?(:cljs
89
(def *thread-apis (volatile! {})))
@@ -28,7 +29,7 @@
2829
(try
2930
(ldb/write-transit-str v)
3031
(catch :default e
31-
(log/error :thread-api-write-transit-failed-2 qualified-kw-str)
32+
(log/error :thread-api-write-transit-failed qualified-kw-str)
3233
(throw e)))))
3334

3435
#?(:cljs

0 commit comments

Comments
 (0)