[WIP] Quotes

This commit is contained in:
Ali
2023-10-13 15:24:53 +04:00
parent 50881b558f
commit a753d71cd7
46 changed files with 2076 additions and 606 deletions

View File

@@ -108,6 +108,8 @@ public final class Logger {
setPostboxLogger({ s in
Logger.shared.log("Postbox", s)
Logger.shared.shortLog("Postbox", s)
}, sync: {
Logger.shared.sync()
})
}
@@ -128,6 +130,14 @@ public final class Logger {
self.basePath = basePath
}
public func sync() {
self.queue.sync {
if let (currentFile, _) = self.file {
let _ = currentFile.sync()
}
}
}
public func collectLogs(prefix: String? = nil) -> Signal<[(String, String)], NoError> {
return Signal { subscriber in
self.queue.async {