mirror of
https://github.com/Novaloop-AG/element-x-ios.git
synced 2026-11-04 10:33:45 +00:00
Log the app version number at the start. (#1993)
This commit is contained in:
@@ -75,6 +75,11 @@ class AppCoordinator: AppCoordinatorProtocol, AuthenticationCoordinatorDelegate,
|
|||||||
MXLog.configure(logLevel: appSettings.logLevel)
|
MXLog.configure(logLevel: appSettings.logLevel)
|
||||||
}
|
}
|
||||||
|
|
||||||
|
let appName = InfoPlistReader.main.bundleDisplayName
|
||||||
|
let appVersion = InfoPlistReader.main.bundleShortVersionString
|
||||||
|
let appBuild = InfoPlistReader.main.bundleVersion
|
||||||
|
MXLog.info("\(appName) \(appVersion) (\(appBuild))")
|
||||||
|
|
||||||
if ProcessInfo.processInfo.environment["RESET_APP_SETTINGS"].map(Bool.init) == true {
|
if ProcessInfo.processInfo.environment["RESET_APP_SETTINGS"].map(Bool.init) == true {
|
||||||
AppSettings.reset()
|
AppSettings.reset()
|
||||||
}
|
}
|
||||||
@@ -298,6 +303,8 @@ class AppCoordinator: AppCoordinatorProtocol, AuthenticationCoordinatorDelegate,
|
|||||||
private func performMigrationsIfNecessary(from oldVersion: Version, to newVersion: Version) {
|
private func performMigrationsIfNecessary(from oldVersion: Version, to newVersion: Version) {
|
||||||
guard oldVersion != newVersion else { return }
|
guard oldVersion != newVersion else { return }
|
||||||
|
|
||||||
|
MXLog.info("The app was upgraded from \(oldVersion) to \(newVersion)")
|
||||||
|
|
||||||
if oldVersion < Version(1, 1, 0) {
|
if oldVersion < Version(1, 1, 0) {
|
||||||
MXLog.info("Migrating to v1.1.0, signing out the user.")
|
MXLog.info("Migrating to v1.1.0, signing out the user.")
|
||||||
// Version 1.1.0 switched the Rust crypto store to SQLite
|
// Version 1.1.0 switched the Rust crypto store to SQLite
|
||||||
@@ -306,7 +313,7 @@ class AppCoordinator: AppCoordinatorProtocol, AuthenticationCoordinatorDelegate,
|
|||||||
}
|
}
|
||||||
|
|
||||||
if oldVersion < Version(1, 1, 7) {
|
if oldVersion < Version(1, 1, 7) {
|
||||||
MXLog.info("Migrating to v1.1.0, marking accounts as migrated.")
|
MXLog.info("Migrating to v1.1.7, marking accounts as migrated.")
|
||||||
for userID in userSessionStore.userIDs {
|
for userID in userSessionStore.userIDs {
|
||||||
appSettings.migratedAccounts[userID] = true
|
appSettings.migratedAccounts[userID] = true
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user