                  {})
                :handler callback
                :error-handler (fn []
-                                (swap! messages conj [:error "Check in failed. Please try again."]))}))
-
-        button-loading? (atom false)]
+                                (swap! messages conj [:error "Check in failed. Please try again."]))}))]
     (fn [event-id attendee-id]
       (let [event (into {} (d/entity @events-db event-id))
 
             attendee
-            (atom (into {} (first (map (fn [[user-id attendee-id]]
-                                         (merge (into {} (d/entity @users-db
-                                                                   user-id))
-                                                (into {} (d/entity @attendees-db
-                                                                   attendee-id))))
-                                       (d/q '[:find ?e ?a
-                                              :in $ ?attendee-id
-                                              :where
-                                              [?a :AttendeeId ?attendee-id]
-                                              [?a :UserId ?e]]
-                                            @attendees-db
-                                            attendee-id)))))
+            (into {} (first (map (fn [[user-id attendee-id]]
+                                   (merge (into {} (d/entity @users-db
+                                                             user-id))
+                                          (into {} (d/entity @attendees-db
+                                                             attendee-id))))
+                                 (d/q '[:find ?e ?a
+                                        :in $ ?attendee-id
+                                        :where
+                                        [?a :AttendeeId ?attendee-id]
+                                        [?a :UserId ?e]]
+                                      @attendees-db
+                                      attendee-id))))
 
             attendee-activities
             (d/q '[:find ?schedule-id ?activity-id

                                            "error")}
              [:label "Organization Name"]
              [input-atom :text (r/wrap Name swap! form assoc :Name)]]]
            [:button.ui.primary.button
             {:type :submit
              :class (when (seq errors) "disabled")
              :on-click #(create-organization % @form)}
             "Add"]]]]]))))

(defn calendar-page []
  (let [user-activities

                             event-id)))

            create-activity
            (fn [form]
              (fn [callback]
                (when (empty? errors)
                  (activities-endpoint :create
                                       (let [start-time (:StartTime form)
                                             end-time   (:EndTime form)]
                                         (assoc form
                                           :StartTime (unparse (:date-hour-minute-second formatters)
                                                               (from-string start-time))
                                           :EndTime (unparse (:date-hour-minute-second formatters)
                                                             (from-string end-time))))
                                       #(do
                                          (callback)
                                          (reset-form!))))))]
        (when (seq event)
          [:div.sixteen.wide.column
           [:div.ui.segment
