mirror of
https://github.com/lux-tel/session-ios.git
synced 2026-10-30 20:38:32 +00:00
24 lines
892 B
Swift
24 lines
892 B
Swift
// Copyright © 2024 Rangeproof Pty Ltd. All rights reserved.
|
|
|
|
import Foundation
|
|
import GRDB
|
|
import SessionUtilitiesKit
|
|
|
|
enum _034_AddMissingWhisperFlag: Migration {
|
|
static let identifier: String = "messagingKit.AddMissingWhisperFlag"
|
|
static let minExpectedRunDuration: TimeInterval = 0.1
|
|
static let createdTables: [(TableRecord & FetchableRecord).Type] = []
|
|
|
|
static func migrate(_ db: ObservingDatabase, using dependencies: Dependencies) throws {
|
|
/// We should have had this column from the very beginning but it was missed, so add it in now for when we eventually
|
|
/// support whispers in Community conversations
|
|
try db.alter(table: "interaction") { t in
|
|
t.add(column: "openGroupWhisper", .boolean)
|
|
.notNull()
|
|
.defaults(to: false)
|
|
}
|
|
|
|
MigrationExecution.updateProgress(1)
|
|
}
|
|
}
|