     userIdsToLookup = (userId for userId, _ of userIds)
     loadUsers(userIdsToLookup)
 
-    @setState {messages}
+    currentParentId = @_getCurrentParentId()
+
+    @setState {messages, currentParentId}
 
   _switchThread: (threadId) ->
     # TODO: Put this in a listener for scrolling of the thread (or better interaction)


    @state.threadMessageMap[threadId].push messageId

  _onMessageStoreUpdate: (messageIds) ->
    messages = @state.messages
    userIds = {}

    if not threadId
      throw new Error "Can't send a message with no thread!"

    parentId = @state.currentParentId
    messageStore.sendNewMessage threadId, content, 0, parentId

  _renderThreadSidebar: ->
    threads = []
