Skip to content

Commit

Permalink
CLJS-590: NPE when using :source-map with :whitespace optimizations
Browse files Browse the repository at this point in the history
  • Loading branch information
swannodette committed Sep 18, 2013
1 parent a2ba719 commit ba475ed
Showing 1 changed file with 7 additions and 6 deletions.
13 changes: 7 additions & 6 deletions src/clj/cljs/closure.clj
Expand Up @@ -722,12 +722,13 @@
(loop [sources (seq sources)
merged (sorted-map-by
(sm/source-compare
(map (fn [source]
(if-let [^URL source-url (:source-url source)]
(.getPath source-url)
(let [^URL url (:url source)]
(.getPath url))))
sources)))]
(remove nil?
(map (fn [source]
(if-let [^URL source-url (:source-url source)]
(.getPath source-url)
(if-let [^URL url (:url source)]
(.getPath url))))
sources))))]
(if sources
(let [source (first sources)]
(recur (next sources)
Expand Down

0 comments on commit ba475ed

Please sign in to comment.