Skip to content
Browse files

Use catch :default in browser repl and reflect

  • Loading branch information...
1 parent a7f7ea3 commit 203d853f1e9c5673cfd987feb7cd07a4762e1479 @brandonbloom brandonbloom committed with swannodette Jan 31, 2014
Showing with 2 additions and 2 deletions.
  1. +1 −1 src/cljs/clojure/browser/repl.cljs
  2. +1 −1 src/cljs/clojure/reflect.cljs
View
2 src/cljs/clojure/browser/repl.cljs
@@ -28,7 +28,7 @@
"Process a single block of JavaScript received from the server"
[conn block]
(let [result (try {:status :success :value (str (js* "eval(~{block})"))}
- (catch js/Error e
+ (catch :default e
{:status :exception :value (pr-str e)
:stacktrace (if (.hasOwnProperty e "stack")
(.-stack e)
View
2 src/cljs/clojure/reflect.cljs
@@ -5,7 +5,7 @@
(defn- evaluate-javascript [block]
(let [result (try (js* "eval(~{block})")
- (catch js/Error e
+ (catch :default e
(.log js/console e)))]
result))

0 comments on commit 203d853

Please sign in to comment.
Something went wrong with that request. Please try again.