fix(thread-list): AccountId resolution for items outside loaded range

This commit is contained in:
Ben Gotow 2016-01-29 17:56:46 -08:00
parent ec553b0c3d
commit c8d8bd0aee

View file

@ -107,11 +107,10 @@ class ThreadList extends React.Component
dataSource = ThreadListStore.dataSource()
if itemThreadId in dataSource.selection.ids()
dragThreadIds = dataSource.selection.ids()
dragAccountIds = _.pluck(dataSource.selection.items(), 'accountId')
else
dragThreadIds = [itemThreadId]
dragAccountIds = dragThreadIds.map (threadId) -> dataSource.getById(threadId).accountId
dragAccountIds = _.uniq(dragAccountIds)
dragAccountIds = [dataSource.getById(itemThreadId).accountId]
dragData = {
accountIds: dragAccountIds,