We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
2 parents 069b1eb + 6851dfb commit 82ff34cCopy full SHA for 82ff34c
Sources/SecureXPC/Server/ClientIdentity.swift
@@ -55,10 +55,10 @@ public extension XPCServer {
55
) rethrows -> R {
56
Thread.current.threadDictionary[contextKey] = XPCServer.ClientIdentity(connection: connection,
57
message: message)
58
- let result = try operation()
59
- Thread.current.threadDictionary.removeObject(forKey: contextKey)
+
+ defer { Thread.current.threadDictionary.removeObject(forKey: contextKey) }
60
61
- return result
+ return try operation()
62
}
63
64
// MARK: current context
0 commit comments