             [ajax.core :refer [PUT GET DELETE]]
             [cljsjs.jquery]
             [cljsjs.fixed-data-table]
-            [rmfu-ui.utils :refer [index-of get-identity-token]]))
+            [rmfu-ui.utils :as utils]))
 
 (declare cell-and-checkbox)
 

  (PUT "/api/block-user"
       {:params        {:email email :blocked? state}
        :format        :json
        :headers       {:identity (get-identity-token)}
        :handler       (fn [res]
                         (alert-update-display-fn (str "User with email: " email " successfully " res)))
        :error-handler #(js/alert %)}))

(defn fetch-all-users []
  (GET "/api/users"
       {:headers         {:identity (get-identity-token)}
        :error-handler   #(secretary/dispatch! "/")
        :response-format :json
        :keywords?       true

(defn cell-and-checkbox [row]
  (let [users (sort-by first (:users @app-state))
        users-table (mapv #(into [] (vals %)) users)
        index (utils/index-of users-table row)
        user (get (:users @app-state) index)]
    [:div.checkbox
     [:label
