File tree Expand file tree Collapse file tree 2 files changed +4
-2
lines changed Expand file tree Collapse file tree 2 files changed +4
-2
lines changed Original file line number Diff line number Diff line change @@ -41,7 +41,7 @@ let package = Package(
41
41
" -warn-concurrency " ,
42
42
" -enable-actor-data-race-checks " ,
43
43
]
44
- )
44
+ ) ,
45
45
]
46
46
) ,
47
47
]
Original file line number Diff line number Diff line change @@ -59,10 +59,12 @@ public class SupabaseClient {
59
59
/// - supabaseURL: Unique Supabase project url
60
60
/// - supabaseKey: Supabase anonymous API Key
61
61
/// - schema: Database schema name, defaults to `public`
62
+ /// - headers: Optional headers for initializing the client.
62
63
public init (
63
64
supabaseURL: URL ,
64
65
supabaseKey: String ,
65
66
schema: String = " public " ,
67
+ headers: [ String : String ] = [ : ] ,
66
68
httpClient: HTTPClient = HTTPClient ( )
67
69
) {
68
70
self . supabaseURL = supabaseURL
@@ -73,7 +75,7 @@ public class SupabaseClient {
73
75
defaultHeaders = [
74
76
" X-Client-Info " : " supabase-swift/ \( version) " ,
75
77
" apikey " : supabaseKey,
76
- ]
78
+ ] . merging ( headers ) { old , _ in old }
77
79
78
80
auth = GoTrueClient (
79
81
url: supabaseURL. appendingPathComponent ( " /auth/v1 " ) ,
You can’t perform that action at this time.
0 commit comments