File tree Expand file tree Collapse file tree 2 files changed +6
-4
lines changed
Expand file tree Collapse file tree 2 files changed +6
-4
lines changed Original file line number Diff line number Diff line change 33 import Security
44
55 struct Keychain {
6- let service : String
6+ let service : String ?
77 let accessGroup : String ?
88
99 init (
10- service: String ,
10+ service: String ? ,
1111 accessGroup: String ? = nil
1212 ) {
1313 self . service = service
5555 private func baseQuery( withKey key: String ? = nil , data: Data ? = nil ) -> [ String : Any ] {
5656 var query : [ String : Any ] = [ : ]
5757 query [ kSecClass as String ] = kSecClassGenericPassword
58- query [ kSecAttrService as String ] = service
5958
59+ if let service {
60+ query [ kSecAttrService as String ] = service
61+ }
6062 if let key {
6163 query [ kSecAttrAccount as String ] = key
6264 }
Original file line number Diff line number Diff line change 55 public struct KeychainLocalStorage : AuthLocalStorage {
66 private let keychain : Keychain
77
8- public init ( service: String = " supabase.gotrue.swift " , accessGroup: String ? = nil ) {
8+ public init ( service: String ? = " supabase.gotrue.swift " , accessGroup: String ? = nil ) {
99 keychain = Keychain ( service: service, accessGroup: accessGroup)
1010 }
1111
You can’t perform that action at this time.
0 commit comments