Skip to content

Commit b196f56

Browse files
committed
fix: reflection errors in service
1 parent ad00799 commit b196f56

File tree

1 file changed

+3
-2
lines changed

1 file changed

+3
-2
lines changed

service/src/stencil/service.clj

+3-2
Original file line numberDiff line numberDiff line change
@@ -9,6 +9,7 @@
99
[stencil.slf4j :as slf4j]
1010
[clojure.data :refer [diff]]
1111
[clojure.java.io :as io :refer [file]]
12+
[clojure.string]
1213
[ring.middleware.json :refer [wrap-json-body]]))
1314

1415
(set! *warn-on-reflection* true)
@@ -64,8 +65,8 @@
6465
(prepared template)
6566
(throw (ex-info "Template file does not exist!" {:status 404})))))
6667

67-
(defn- exception->str [e]
68-
(clojure.string/join "\n" (for [e (iterate #(.getCause %) e) :while e] (.getMessage e))))
68+
(defn- exception->str [^Exception e]
69+
(clojure.string/join "\n" (for [^Exception e (iterate #(.getCause ^Exception %) e) :while e] (.getMessage e))))
6970

7071
(defn wrap-err [handler]
7172
(fn [request]

0 commit comments

Comments
 (0)