diff --git a/Config/BuildSettings.swift b/Config/BuildSettings.swift index bb1b25a0a..4daf809ad 100644 --- a/Config/BuildSettings.swift +++ b/Config/BuildSettings.swift @@ -133,8 +133,14 @@ final class BuildSettings: NSObject { // Official Matrix ones "matrix.to": ["/"], "www.matrix.to": ["/"], + // Client Permalinks (for use with `BuildSettings.clientPermalinkBaseUrl`) +// "clienturl.com": ["/"], +// "www.clienturl.com": ["/"], ] + // For use in clients that use a custom base url for permalinks rather than matrix.to. + // This baseURL is used to generate permalinks within the app (E.g. timeline message permalinks). + static let clientPermalinkBaseUrl: String? = nil // MARK: - VoIP static var allowVoIPUsage: Bool { diff --git a/Config/CommonConfiguration.swift b/Config/CommonConfiguration.swift index b6aa77dad..f2e4b68dc 100644 --- a/Config/CommonConfiguration.swift +++ b/Config/CommonConfiguration.swift @@ -75,6 +75,7 @@ class CommonConfiguration: NSObject, Configurable { // Disable key backup on common sdkOptions.enableKeyBackupWhenStartingMXCrypto = false + sdkOptions.clientPermalinkBaseUrl = BuildSettings.clientPermalinkBaseUrl // Configure key provider delegate MXKeyProvider.sharedInstance().delegate = EncryptionKeyManager.shared }