                   "referer" (route_param "referer")}]
       (if (not(nil? params))
         (do (println "initial param was:" params)
-            (updatedb [:editing] params)
-            (.route js/m "/")))))
+            (.route js/m "/")
+            (updatedb [:editing] params)))))
   (println "No auth!"))
 
 ;; (require '[modern-cljs.core :as c] :reload)
 ;; alt cmd e -> search repl history
+;; (.route js/m "/")


(enable-console-print!)

(js/setup_dropbox)

(defn setup []
  (do
    (set! (.-mode (.-route js/m)) "hash")
    (.route js/m
            (.getElementById js/document "app")
            "/"
            (clj->js {"/" app}))))

(if (and (not (nil? js/client)) (.isAuthenticated js/client))
  (do
    (setup)

;

(def ^:const PAGESIZE 10)
(def ^:const DB "/data2.json")

;
; Mithril helpers
