 
     @cache.users
 
+  userDiscussions: =>
+    if !@cache.userDiscussions
+      @cache.userDiscussions = _.filter @state.discussions, (d) => d.user_id == @state.user.id
+
+    @cache.userDiscussions
+
 
   ujsDiscussionUpdate: (_e, data) =>
     # to allow ajax:complete to be run


      users.push(newUser)

    @cache.users = @cache.discussions = @cache.beatmaps = null
    @setState
      discussions: _.reverse(_.sortBy(discussions, (d) -> Date.parse(d.starting_post.created_at)))
      posts: _.reverse(_.sortBy(posts, (p) -> Date.parse(p.created_at)))

    switch name
      when 'discussions'
        props:
          discussions: @userDiscussions()
          user: @state.user
          users: @users()
        component: Discussions
