mirror of
https://github.com/quik-sms/quik.git
synced 2026-11-17 19:38:52 +01:00
Merge remote-tracking branch 'upstream/master' into emoji-reacts
This commit is contained in:
@@ -36,7 +36,7 @@ class QkRealmMigration @Inject constructor(
|
||||
) : RealmMigration {
|
||||
|
||||
companion object {
|
||||
const val SchemaVersion: Long = 13
|
||||
const val SchemaVersion: Long = 14
|
||||
}
|
||||
|
||||
@SuppressLint("ApplySharedPref")
|
||||
@@ -239,10 +239,6 @@ class QkRealmMigration @Inject constructor(
|
||||
// Because there was never any property associated with which conversation/recipients a scheduled message was for,
|
||||
// we can't update this field on a realm migration. It will be set to a default of 0
|
||||
|
||||
version++
|
||||
}
|
||||
|
||||
if (version == 11L) {
|
||||
realm.schema.create("MessageContentFilter")
|
||||
.addField("id", Long::class.java, FieldAttribute.PRIMARY_KEY, FieldAttribute.REQUIRED)
|
||||
.addField("value", String::class.java, FieldAttribute.REQUIRED)
|
||||
@@ -254,6 +250,13 @@ class QkRealmMigration @Inject constructor(
|
||||
}
|
||||
|
||||
if (version == 12L) {
|
||||
realm.schema.get("Conversation")
|
||||
?.addField("draftDate", Long::class.java, FieldAttribute.REQUIRED)
|
||||
|
||||
version++
|
||||
}
|
||||
|
||||
if (version == 13L) {
|
||||
val emojiReactionTable = realm.schema.create("EmojiReaction")
|
||||
.addField("id", Long::class.java, FieldAttribute.PRIMARY_KEY, FieldAttribute.REQUIRED)
|
||||
.addField("reactionMessageId", Long::class.java, FieldAttribute.INDEXED, FieldAttribute.REQUIRED)
|
||||
|
||||
Reference in New Issue
Block a user