                                    (iframeio-upload-file "upload-form"
                                                          owner))
                        :action "/api/new-stream"}
-          (dom/input #js {:type "hidden" :name "token"
-                          :value (ck/get "token")} nil)
           (dom/h1 #js {:className "view-title"} "New Stream")
           (:upload-status state)
           (dom/div

  ([f url]
   (call-api f url ""))
  ([f url qs]
   (let [token (ck/get "token")
         tk (str "access_token=" token)
         query (str url "?" (if (or (nil? qs) (= "" qs))
                              tk
                              (clojure.string/join "&" [qs tk])))]
     #_(.log js/console query)
     (f query))))

(defn call-oauth [f & args]
  (let [token (ck/get "token")
        new-m (if (nil? token)
                {}
                {:default-headers {"authorization" (str "Token " token)}})
        m (if (> (count args) 1)
            (merge (second args) new-m)
            new-m)]
    #_(.log js/console (pr-str m))
    (f (first args) m)))


                  (om/update-state! owner (fn [old] (assoc old k v))))
            g (fn [k] (get state k))
            fn-post (fn []
                      (client/get "/auth/login"
                                  {:basic-auth {:username (g :username)
                                                :password (g :password)}}))
            fn-clk (fn [_]
                     (go (let [res (<! (fn-post))]
                           (upd :auth res))))]
        (if (= 200 (:status (:auth state)))
          (set! (.-location js/window) "/ui")
          (dom/div nil
