mirror of
https://github.com/Novaloop-AG/element-x-ios.git
synced 2026-11-04 01:20:12 +00:00
Fix for NSE and ShareExtension individual builds (#5856)
This commit is contained in:
@@ -8,7 +8,9 @@
|
|||||||
|
|
||||||
import Combine
|
import Combine
|
||||||
import Foundation
|
import Foundation
|
||||||
|
#if IS_MAIN_APP
|
||||||
import MapLibre
|
import MapLibre
|
||||||
|
#endif
|
||||||
import MatrixRustSDK
|
import MatrixRustSDK
|
||||||
|
|
||||||
nonisolated enum Target: String {
|
nonisolated enum Target: String {
|
||||||
@@ -63,6 +65,18 @@ nonisolated enum Target: String {
|
|||||||
|
|
||||||
MXLog.configure(currentTarget: rawValue)
|
MXLog.configure(currentTarget: rawValue)
|
||||||
|
|
||||||
|
configureMapLibreIfAvailable()
|
||||||
|
|
||||||
|
let hookCancellable = rageshakeURL.publisher
|
||||||
|
.sink { _ in
|
||||||
|
appHooks.tracingHook.update(tracingConfiguration, with: rageshakeURL)
|
||||||
|
}
|
||||||
|
|
||||||
|
return ConfigurationResult(hookCancellable: hookCancellable)
|
||||||
|
}
|
||||||
|
|
||||||
|
private func configureMapLibreIfAvailable() {
|
||||||
|
#if IS_MAIN_APP
|
||||||
MLNLoggingConfiguration.shared.loggingLevel = .debug
|
MLNLoggingConfiguration.shared.loggingLevel = .debug
|
||||||
MLNLoggingConfiguration.shared.handler = { loggingLevel, _, _, message in
|
MLNLoggingConfiguration.shared.handler = { loggingLevel, _, _, message in
|
||||||
switch loggingLevel {
|
switch loggingLevel {
|
||||||
@@ -80,13 +94,7 @@ nonisolated enum Target: String {
|
|||||||
break
|
break
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
#endif
|
||||||
let hookCancellable = rageshakeURL.publisher
|
|
||||||
.sink { _ in
|
|
||||||
appHooks.tracingHook.update(tracingConfiguration, with: rageshakeURL)
|
|
||||||
}
|
|
||||||
|
|
||||||
return ConfigurationResult(hookCancellable: hookCancellable)
|
|
||||||
}
|
}
|
||||||
|
|
||||||
/// The result of calling ``configure(logLevel:traceLogPacks:sentryURL:)``.
|
/// The result of calling ``configure(logLevel:traceLogPacks:sentryURL:)``.
|
||||||
|
|||||||
Reference in New Issue
Block a user