     (.-value (dom/getElement "directions-to"))))
 
 (defn remove-explanation-text []
-  (.remove (dom/getElement "explanation")))
+  (if-let [node (dom/getElement "explanation")]
+    (.remove node)))
 
 (defn section-id [num]
   (str "biz-" num))

        (.start (.create js/Ladda ;; starts loading spinner
                         (dom/getElement "btn-go")))
        ;; clear existing map's directions
        (remove-explanation-text) ;; clear text (if not already cleared)
        (direction-steps mappy (from-query) (to-query)) ;; draw map's directions
        )))

(defn geolocation [position]

(defn find-marker-2 []
  (dom/getElementsByClass "number"))

(defn remove-marker [layer num]
  (let [marker (get @biz-layer-items num)]
    (swap! biz-layer-items dissoc num)
    (.removeLayer layer marker)))

(defn url-encode [s]
  (js/encodeURIComponent s))
