mirror of
https://github.com/outbackdingo/firezone.git
synced 2026-01-27 10:18:54 +00:00
refactor(apple): use guard for checking valid handle (#9614)
Follow-up to #9597
This commit is contained in:
@@ -238,11 +238,9 @@ private final class LogWriter {
|
||||
|
||||
workQueue.async { [weak self] in
|
||||
guard let self = self else { return }
|
||||
guard let handle = self.ensureFileExists() else { return }
|
||||
|
||||
// Get valid handle, recreating file if necessary
|
||||
if let handle = self.ensureFileExists() {
|
||||
handle.write(jsonData)
|
||||
}
|
||||
handle.write(jsonData)
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user