Fix inconsistencies found by consistency audit of 4e20fe8
This commit is contained in:
@@ -393,11 +393,15 @@ func chromeFromProfile() async -> Chrome? {
|
||||
}
|
||||
|
||||
func openChrome() async throws -> (Chrome, String) {
|
||||
if let chrome = await chromeFromProfile() { return (chrome, "") }
|
||||
if let chrome = await chromeFromProfile() {
|
||||
return (chrome, "")
|
||||
}
|
||||
let lock = try await lockInput()
|
||||
defer { close(lock) }
|
||||
// Another helper may have started Chrome while this one waited.
|
||||
if let chrome = await chromeFromProfile() { return (chrome, "") }
|
||||
if let chrome = await chromeFromProfile() {
|
||||
return (chrome, "")
|
||||
}
|
||||
let fm = FileManager.default
|
||||
try fm.createDirectory(atPath: chromeProfile, withIntermediateDirectories: true, attributes: [.posixPermissions: 0o700])
|
||||
try fm.setAttributes([.posixPermissions: 0o700], ofItemAtPath: chromeProfile)
|
||||
|
||||
Reference in New Issue
Block a user