Skip to content

Commit

Permalink
IOS-2816 Consistency
Browse files Browse the repository at this point in the history
  • Loading branch information
megakoko committed Jan 12, 2023
1 parent 7551378 commit e425dcc
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 5 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -61,7 +61,7 @@ public class BiometricsStorage {

var status = SecItemAdd(query as CFDictionary, nil)

Log.debug("BiometricsStorage store - status \(status.message) \(status)")
Log.debug("BiometricsStorage set - status \(status.message) \(status)")

if status == errSecDuplicateItem && overwrite {
var searchQuery: [CFString: Any] = [
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -55,11 +55,9 @@ public struct SecureStorage {

var status = SecItemAdd(query as CFDictionary, nil)

Log.debug("SecureStorage store - status \(status.message) \(status)")
Log.debug("SecureStorage set - status \(status.message) \(status)")

if status == errSecDuplicateItem && overwrite {
Log.debug("SecureStorage store - failed to write, overwriting")

let searchQuery: [CFString: Any] = [
kSecClass: kSecClassGenericPassword,
kSecAttrAccount: account,
Expand All @@ -69,7 +67,7 @@ public struct SecureStorage {

status = SecItemUpdate(searchQuery as CFDictionary, attributes as CFDictionary)

Log.debug("SecureStorage store - overwrite status \(status.message) \(status)")
Log.debug("SecureStorage set - overwrite status \(status.message) \(status)")
}

guard status == errSecSuccess else {
Expand Down

0 comments on commit e425dcc

Please sign in to comment.