Commit b50ce164c2

b50ce164c2ff8b87dcc4256e1b3c97994dc431f8

parent: 52d620b11e

Verified · cmc

cmc <hello@cleberg.net> · 2026-11-26 16:13 UTC

Stop deleting when no passphrase is left

Ref #239

Layout: unified · split

Sources/OrgApp/CryptPassphrases.swift +2 −1 · view
@@ -290,7 +290,8 @@ public final class SystemKeychain: PassphraseKeychain {
290290 public func deleteAll() {
291291 for service in [CryptPassphrases.service, CryptPassphrases.legacyService] {
292292 // The file-based keychain may delete one match per call.
293 for _ in 0..<1000 where SecItemDelete(Self.query(nil, service: service) as CFDictionary) == errSecSuccess {}
293 var count = 0
294 while count < 1000, SecItemDelete(Self.query(nil, service: service) as CFDictionary) == errSecSuccess { count += 1 }
294295 }
295296 }
296297
Keyboard shortcuts

Global

⌘K
Command palette & jump
/
Focus search
?
Show this help
g d
Dashboard
g e
Explore repositories
g n
Notifications

Repository & editor

t
Find file in repository
y
Copy immutable SHA permalink
g c
Code tab
g i
Issues tab
g m
Merge requests tab
g b
Builds tab
⌘↵
Submit active form