forked from upstream-mirrors/quik
fix crash when conversation is deleted
This commit is contained in:
@@ -26,7 +26,11 @@ class MessageListActivity : QkActivity() {
|
|||||||
.inject(this)
|
.inject(this)
|
||||||
|
|
||||||
viewModel.conversation.addChangeListener { realmResults ->
|
viewModel.conversation.addChangeListener { realmResults ->
|
||||||
title = realmResults[0]?.getTitle()
|
if (realmResults.size > 0) {
|
||||||
|
title = realmResults[0]?.getTitle()
|
||||||
|
} else {
|
||||||
|
finish()
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
val layoutManager = LinearLayoutManager(this)
|
val layoutManager = LinearLayoutManager(this)
|
||||||
|
|||||||
Reference in New Issue
Block a user