Skip to content

Commit

Permalink
updated access to JS static properties. Needed from CLJS 0.0-1933 on
Browse files Browse the repository at this point in the history
  • Loading branch information
magomimmo committed Oct 25, 2013
1 parent 74dbdb3 commit ba8cd1c
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions src/cljs/domina/xpath.cljs
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@
(.selectSingleNode node expr))
(fn [resolver doc node expr]
(let [result (.evaluate doc expr node nil
XPathResult/FIRST_ORDERED_NODE_TYPE nil)]
js/XPathResult.FIRST_ORDERED_NODE_TYPE nil)]
(. result -singleNodeValue)))))

(defn- select-nodes
Expand All @@ -38,7 +38,7 @@
(.selectNodes node expr))
(fn [resolver doc node expr]
(let [result (.evaluate doc expr node nil
XPathResult/ORDERED_NODE_SNAPSHOT_TYPE nil)
js/XPathResult.ORDERED_NODE_SNAPSHOT_TYPE nil)
num-results (.-snapshotLength result)]
(loop [i 0 acc nil]
(if (< i num-results)
Expand All @@ -56,4 +56,4 @@
(nodes [_] (mapcat (partial select-nodes expr) (domina/nodes base)))
(single-node [_] (first (filter (complement nil?)
(map (partial select-node expr)
(domina/nodes base))))))))
(domina/nodes base))))))))

0 comments on commit ba8cd1c

Please sign in to comment.