Skip to content

Commit a3c2d6a

Browse files
committed
Adopt MultiAPIClientDelegate from GetExtensions
1 parent fe09b33 commit a3c2d6a

File tree

4 files changed

+13
-52
lines changed

4 files changed

+13
-52
lines changed

Package.resolved

+9
Original file line numberDiff line numberDiff line change
@@ -10,6 +10,15 @@
1010
"version": "2.1.5"
1111
}
1212
},
13+
{
14+
"package": "GetExtensions",
15+
"repositoryURL": "https://github.com/binaryscraping/GetExtensions",
16+
"state": {
17+
"branch": null,
18+
"revision": "aa20f38721142eb6592b2c8f11179d32d7d70ae3",
19+
"version": "1.0.0"
20+
}
21+
},
1322
{
1423
"package": "swift-snapshot-testing",
1524
"repositoryURL": "https://github.com/pointfreeco/swift-snapshot-testing.git",

Package.swift

+2
Original file line numberDiff line numberDiff line change
@@ -21,12 +21,14 @@ let package = Package(
2121
dependencies: [
2222
.package(url: "https://github.com/pointfreeco/swift-snapshot-testing", from: "1.8.1"),
2323
.package(url: "https://github.com/kean/Get", from: "2.1.4"),
24+
.package(url: "https://github.com/binaryscraping/GetExtensions", from: "1.0.0"),
2425
],
2526
targets: [
2627
.target(
2728
name: "PostgREST",
2829
dependencies: [
2930
"Get",
31+
"GetExtensions",
3032
]
3133
),
3234
.testTarget(

Sources/PostgREST/MultiAPIClientDelegate.swift

-51
This file was deleted.

Sources/PostgREST/PostgrestClient.swift

+2-1
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,6 @@
11
import Foundation
22
import Get
3+
import GetExtensions
34

45
/// PostgREST client.
56
public class PostgrestClient {
@@ -28,7 +29,7 @@ public class PostgrestClient {
2829
$0.decoder = .postgrest
2930
$0.encoder = .postgrest
3031
if let customDelegate = apiClientDelegate {
31-
$0.delegate = MultiAPIClientDelegate([PostgrestAPIClientDelegate(), customDelegate])
32+
$0.delegate = MultiAPIClientDelegate([customDelegate, PostgrestAPIClientDelegate()])
3233
} else {
3334
$0.delegate = PostgrestAPIClientDelegate()
3435
}

0 commit comments

Comments
 (0)