From 2e7d78ea01246df303a75ddfc3dd48d5baec7820 Mon Sep 17 00:00:00 2001 From: Stefan Ceriu Date: Wed, 23 Sep 2026 10:00:17 +0300 Subject: [PATCH] Remove the automatic back pagination feature flag. Automatic back pagination is now always enabled when building the client, so the setting and its developer options toggle have been removed. --- ElementX/Sources/Application/Settings/AppSettings.swift | 3 --- .../DeveloperOptionsScreenModels.swift | 1 - .../DeveloperOptionsScreen/View/DeveloperOptionsScreen.swift | 5 ----- ElementX/Sources/Services/Client/ClientFactory.swift | 4 ++-- 4 files changed, 2 insertions(+), 11 deletions(-) diff --git a/ElementX/Sources/Application/Settings/AppSettings.swift b/ElementX/Sources/Application/Settings/AppSettings.swift index 5b93ae296..e06f48c67 100644 --- a/ElementX/Sources/Application/Settings/AppSettings.swift +++ b/ElementX/Sources/Application/Settings/AppSettings.swift @@ -463,9 +463,6 @@ final nonisolated class AppSettings: @unchecked Sendable { @UserPreference(defaultValue: false) var linkNewDeviceEnabled: Bool - @UserPreference(defaultValue: false) - var automaticBackPaginationEnabled: Bool - @UserPreference(key: "clientPausingAndResumingEnabledV2", defaultValue: false, volatile: true) var clientPausingAndResumingEnabled: Bool diff --git a/ElementX/Sources/Screens/Settings/DeveloperOptionsScreen/DeveloperOptionsScreenModels.swift b/ElementX/Sources/Screens/Settings/DeveloperOptionsScreen/DeveloperOptionsScreenModels.swift index 4293d73c4..203c842e6 100644 --- a/ElementX/Sources/Screens/Settings/DeveloperOptionsScreen/DeveloperOptionsScreenModels.swift +++ b/ElementX/Sources/Screens/Settings/DeveloperOptionsScreen/DeveloperOptionsScreenModels.swift @@ -56,7 +56,6 @@ protocol DeveloperOptionsProtocol: AnyObject { var enableOnlySignedDeviceIsolationMode: Bool { get set } var hideQuietNotificationAlerts: Bool { get set } var focusEventOnNotificationTap: Bool { get set } - var automaticBackPaginationEnabled: Bool { get set } var roomListActivityVisibility: RoomListActivityVisibility { get set } var roomListNotificationCountEnabled: Bool { get set } diff --git a/ElementX/Sources/Screens/Settings/DeveloperOptionsScreen/View/DeveloperOptionsScreen.swift b/ElementX/Sources/Screens/Settings/DeveloperOptionsScreen/View/DeveloperOptionsScreen.swift index 569143ef9..6291176f7 100644 --- a/ElementX/Sources/Screens/Settings/DeveloperOptionsScreen/View/DeveloperOptionsScreen.swift +++ b/ElementX/Sources/Screens/Settings/DeveloperOptionsScreen/View/DeveloperOptionsScreen.swift @@ -83,11 +83,6 @@ struct DeveloperOptionsScreen: View { Toggle(isOn: $context.mentionsFilterEnabled) { Text("Mentions filter") } - - Toggle(isOn: $context.automaticBackPaginationEnabled) { - Text("Automatic back pagination") - Text("Requires app reboot") - } } Section("Room") { diff --git a/ElementX/Sources/Services/Client/ClientFactory.swift b/ElementX/Sources/Services/Client/ClientFactory.swift index c7c09fba3..275386a1f 100644 --- a/ElementX/Sources/Services/Client/ClientFactory.swift +++ b/ElementX/Sources/Services/Client/ClientFactory.swift @@ -26,7 +26,7 @@ nonisolated struct ClientFactory: ClientFactoryProtocol { appHooks: appHooks, enableOnlySignedDeviceIsolationMode: appSettings.enableOnlySignedDeviceIsolationMode, threadsEnabled: appSettings.threadsEnabled) - .enableAutomaticBackPagination(enableAutomaticBackPagination: appSettings.automaticBackPaginationEnabled) + .enableAutomaticBackPagination(enableAutomaticBackPagination: true) .sqliteStore(config: .init(dataPath: sessionDirectories.dataPath, cachePath: sessionDirectories.cachePath) .passphrase(passphrase: passphrase)) .serverNameOrHomeserverUrl(serverNameOrUrl: serverNameOrBaseURL) @@ -64,7 +64,7 @@ nonisolated struct ClientFactory: ClientFactoryProtocol { appHooks: appHooks, enableOnlySignedDeviceIsolationMode: appSettings.enableOnlySignedDeviceIsolationMode, threadsEnabled: appSettings.threadsEnabled) - .enableAutomaticBackPagination(enableAutomaticBackPagination: appSettings.automaticBackPaginationEnabled) + .enableAutomaticBackPagination(enableAutomaticBackPagination: true) .sqliteStore(config: .init(dataPath: credentials.restorationToken.sessionDirectories.dataPath, cachePath: credentials.restorationToken.sessionDirectories.cachePath) .passphrase(passphrase: credentials.restorationToken.passphrase))