mirror of
https://github.com/Swiftgram/Telegram-iOS.git
synced 2025-07-31 07:30:40 +00:00
Change default logging settings
This commit is contained in:
parent
1bbce49b86
commit
9ab9a30dc7
@ -719,14 +719,19 @@ private final class NotificationServiceHandler {
|
||||
|
||||
let semaphore = DispatchSemaphore(value: 0)
|
||||
var loggingSettings = LoggingSettings.defaultSettings
|
||||
let _ = (self.accountManager.transaction { transaction -> LoggingSettings in
|
||||
if buildConfig.isInternalBuild {
|
||||
loggingSettings = LoggingSettings(logToFile: true, logToConsole: false, redactSensitiveData: true)
|
||||
}
|
||||
let _ = (self.accountManager.transaction { transaction -> LoggingSettings? in
|
||||
if let value = transaction.getSharedData(SharedDataKeys.loggingSettings)?.get(LoggingSettings.self) {
|
||||
return value
|
||||
} else {
|
||||
return LoggingSettings.defaultSettings
|
||||
return nil
|
||||
}
|
||||
}).start(next: { value in
|
||||
loggingSettings = value
|
||||
if let value {
|
||||
loggingSettings = value
|
||||
}
|
||||
semaphore.signal()
|
||||
})
|
||||
semaphore.wait()
|
||||
|
Loading…
x
Reference in New Issue
Block a user