 (defn queue-track-view [track owner]
   (reify
     om/IRenderState
-    (render-state [this {:keys [dequeue]}]
+    (render-state [this {:keys [index]}]
       (dom/div #js {:className "track"}
                (dom/span #js {:className "artist"} (get track "artist"))
                (dom/span #js {:className "album"} (get track "album" ))
                (dom/span #js {:className "title"} (get track "title"))
                (dom/span #js {:className "duration"} (mmss (get track "length")))
-               (dom/button #js {:onClick (fn [e] (put! dequeue @track))}
+               (dom/button #js {:onClick #(dequeue-track index)}
                            "-")))))
 
 (defn queue-view [app owner]

      (let [queue (om/observe owner (player-queue))
        bits (best-media-url (first queue))]
        (dom/div nil
                 (dom/audio #js {:controls true
                                 :autoPlay true
                                 :ref "player"
                                 :src bits
                                 })

               (om/build results-view app {:init-state state})
               (dom/h2 nil "queue")
               (om/build queue-view app {:init-state state})
               (om/build player-view app )
               ))))

(defn init []
