mirror of
https://github.com/ChronosX88/Influence.git
synced 2024-11-09 12:01:01 +00:00
Fixed bug with new message in non-existing chat (in Dialog list)
This commit is contained in:
parent
33a8289177
commit
82bd46f306
@ -124,7 +124,7 @@ public class DialogListPresenter implements CoreContracts.IDialogListPresenterCo
|
||||
dialogListAdapter.upsertItem(new GenericDialog(LocalDBWrapper.getChatByChatID(event.chatID)));
|
||||
}
|
||||
|
||||
@Subscribe
|
||||
@Subscribe(threadMode = ThreadMode.MAIN)
|
||||
public void onNewMessage(NewMessageEvent event) {
|
||||
String chatID = event.chatID;
|
||||
GenericDialog dialog = dialogListAdapter.getItemById(chatID);
|
||||
@ -154,6 +154,7 @@ public class DialogListPresenter implements CoreContracts.IDialogListPresenterCo
|
||||
dialog.setLastMessage(new GenericMessage(messageEntity));
|
||||
}
|
||||
dialogListAdapter.upsertItem(dialog);
|
||||
dialogListAdapter.notifyDataSetChanged();
|
||||
});
|
||||
}
|
||||
});
|
||||
|
Loading…
Reference in New Issue
Block a user