RoomSummary : clean some old code

This commit is contained in:
ganfra 2019-01-07 15:20:56 +01:00
parent 7669a94a64
commit f5d64a5707
2 changed files with 9 additions and 16 deletions

View File

@ -13,7 +13,6 @@ internal open class RoomSummaryEntity(@PrimaryKey var roomId: String = "",
var joinedMembersCount: Int? = 0,
var invitedMembersCount: Int? = 0,
var isDirect: Boolean = false,
var isLatestSelected: Boolean = false,
var otherMemberIds: RealmList<String> = RealmList()
) : RealmObject() {


View File

@ -13,9 +13,3 @@ internal fun RoomSummaryEntity.Companion.where(realm: Realm, roomId: String? = n
}
return query
}

internal fun RoomSummaryEntity.Companion.lastSelected(realm: Realm): RoomSummaryEntity? {
return realm.where<RoomSummaryEntity>()
.equalTo(RoomSummaryEntityFields.IS_LATEST_SELECTED, true)
.findFirst()
}