            [:div.ui.vertical.segment
             [:h1.ui.header "Events You're Attending"]]
            [:div.ui.vertical.segment
-            [:div.ui.divided.items
-             (for [event attending-events]
-               ^{:key (:EventId event)}
-               [:div.item
-                [:div.content
-                 [:a.header {:href (event-route event)}
-                  (:Name event)]
-                 [:div.meta
-                  [:strong "Date:"]
-                  (let [start (from-string (:StartDate event))
-                        end   (from-string (:EndDate   event))]
-                    (str (unparse datetime-formatter start)
-                         (when (after? end start)
-                           (str " to " (unparse datetime-formatter end)))))]
-                 [:div.meta
-                  [:strong "Venue:"]
-                  (:Venue event)]
-                 [:div.description
-                  (:Description event)]
-                 [:div.extra
-                  [:a.ui.right.floated.small.button {:href (event-schedule-route event)}
-                   "Your activities"
-                   [:i.right.chevron.icon]]
-                  [:a.ui.right.floated.small.button
-                   {:on-click #(leave-event (:AttendeeId event))}
-                   [:i.red.remove.icon]
-                   "Leave event"]]]])]]]
+            (if (seq attending-events)
+              [:div.ui.divided.items
+               (for [event attending-events]
+                 ^{:key (:EventId event)}
+                 [:div.item
+                  [:div.content
+                   [:a.header {:href (event-route event)}
+                    (:Name event)]
+                   [:div.meta
+                    [:strong "Date:"]
+                    (let [start (from-string (:StartDate event))
+                          end   (from-string (:EndDate   event))]
+                      (str (unparse datetime-formatter start)
+                           (when (after? end start)
+                             (str " to " (unparse datetime-formatter end)))))]
+                   [:div.meta
+                    [:strong "Venue:"]
+                    (:Venue event)]
+                   [:div.description
+                    (:Description event)]
+                   [:div.extra
+                    [:a.ui.right.floated.small.button {:href (event-schedule-route event)}
+                     "Your activities"
+                     [:i.right.chevron.icon]]
+                    [:a.ui.right.floated.small.button
+                     {:on-click #(leave-event (:AttendeeId event))}
+                     [:i.red.remove.icon]
+                     "Leave event"]]]])]
+              [:p "You aren't attending any events."])]]
           [:div.ui.dimmer {:class (when (empty? @events) "active")}
            [:div.ui.loader]]]]))))
 

           :read   (GET  uri options)
           :update (check-id PUT)
           :delete (check-id DELETE)
           (POST (str uri "/" (name operation)) options)))))
    ([operation params handler]
     (dispatch! operation params handler nil))))

                                     inclusion-of
                                     numericality-of
                                     presence-of
                                     length-of
                                     valid?
                                     validation-set]])
    (:require-macros [elevent-client.core :refer [endpoints]])
