From 69db51da5e9d151d8deaa97e99368c5d3428228e Mon Sep 17 00:00:00 2001 From: Matteo Matassoni <4108197+matax87@users.noreply.github.com> Date: Wed, 22 Nov 2023 10:33:26 +0100 Subject: [PATCH] the app compiles again --- .../xcshareddata/swiftpm/Package.resolved | 40 +++++++++---------- .../ArticlesClientLive/Endpoints.swift | 10 ++--- .../Sources/EventShortClientLive/Live.swift | 4 +- .../EventShortTypesClientLive/Live.swift | 2 +- .../Sources/PeopleClientLive/Live.swift | 6 +-- 5 files changed, 30 insertions(+), 32 deletions(-) diff --git a/NOICommunity.xcodeproj/project.xcworkspace/xcshareddata/swiftpm/Package.resolved b/NOICommunity.xcodeproj/project.xcworkspace/xcshareddata/swiftpm/Package.resolved index bf79618..e1f23d0 100644 --- a/NOICommunity.xcodeproj/project.xcworkspace/xcshareddata/swiftpm/Package.resolved +++ b/NOICommunity.xcodeproj/project.xcworkspace/xcshareddata/swiftpm/Package.resolved @@ -15,8 +15,8 @@ "repositoryURL": "https://github.com/openid/AppAuth-iOS.git", "state": { "branch": null, - "revision": "3d36a58a2b736f7bc499453e996a704929b25080", - "version": "1.6.0" + "revision": "71cde449f13d453227e687458144bde372d30fc7", + "version": "1.6.2" } }, { @@ -33,8 +33,8 @@ "repositoryURL": "https://github.com/Kitura/BlueECC.git", "state": { "branch": null, - "revision": "baf6ed3fc1a622675f0041b4aff7c02dd1a93818", - "version": "1.2.200" + "revision": "1485268a54f8135435a825a855e733f026fa6cc8", + "version": "1.2.201" } }, { @@ -78,8 +78,8 @@ "repositoryURL": "https://github.com/google/GoogleDataTransport.git", "state": { "branch": null, - "revision": "5056b15c5acbb90cd214fe4d6138bdf5a740e5a8", - "version": "9.2.0" + "revision": "aae45a320fd0d11811820335b1eabc8753902a40", + "version": "9.2.5" } }, { @@ -87,8 +87,8 @@ "repositoryURL": "https://github.com/google/GoogleUtilities.git", "state": { "branch": null, - "revision": "22907832079d808e82f1182b21af58ef3880666f", - "version": "7.8.0" + "revision": "bc27fad73504f3d4af235de451f02ee22586ebd3", + "version": "7.12.1" } }, { @@ -105,8 +105,8 @@ "repositoryURL": "https://github.com/google/gtm-session-fetcher.git", "state": { "branch": null, - "revision": "d4289da23e978f37c344ea6a386e5546e2466294", - "version": "2.1.0" + "revision": "5ccda3981422a84186387dbb763ba739178b529c", + "version": "2.3.0" } }, { @@ -123,8 +123,8 @@ "repositoryURL": "https://github.com/onevcat/Kingfisher.git", "state": { "branch": null, - "revision": "be1a1acb283a702b99b630f586877ba02234b4cb", - "version": "7.3.2" + "revision": "277f1ab2c6664b19b4a412e32b094b201e2d5757", + "version": "7.10.0" } }, { @@ -141,8 +141,8 @@ "repositoryURL": "https://github.com/firebase/leveldb.git", "state": { "branch": null, - "revision": "0706abcc6b0bd9cedfbb015ba840e4a780b5159b", - "version": "1.22.2" + "revision": "9d108e9112aa1d65ce508facf804674546116d9c", + "version": "1.22.3" } }, { @@ -168,8 +168,8 @@ "repositoryURL": "https://github.com/google/promises.git", "state": { "branch": null, - "revision": "3e4e743631e86c8c70dbc6efdc7beaa6e90fd3bb", - "version": "2.1.1" + "revision": "e70e889c0196c76d22759eb50d6a0270ca9f1d9e", + "version": "2.3.1" } }, { @@ -186,8 +186,8 @@ "repositoryURL": "https://github.com/apple/swift-log.git", "state": { "branch": null, - "revision": "6fe203dc33195667ce1759bf0182975e4653ba1c", - "version": "1.4.4" + "revision": "532d8b529501fb73a2455b179e0bbb6d49b652ed", + "version": "1.5.3" } }, { @@ -195,8 +195,8 @@ "repositoryURL": "https://github.com/apple/swift-protobuf.git", "state": { "branch": null, - "revision": "b8230909dedc640294d7324d37f4c91ad3dcf177", - "version": "1.20.1" + "revision": "07f7f26ded8df9645c072f220378879c4642e063", + "version": "1.25.1" } } ] diff --git a/NOICommunityLib/Sources/ArticlesClientLive/Endpoints.swift b/NOICommunityLib/Sources/ArticlesClientLive/Endpoints.swift index 0b7742a..7e28556 100644 --- a/NOICommunityLib/Sources/ArticlesClientLive/Endpoints.swift +++ b/NOICommunityLib/Sources/ArticlesClientLive/Endpoints.swift @@ -30,12 +30,10 @@ extension Endpoint { pageNumber: Int? ) -> Endpoint { Self(path: "/v1/Article") { - if let startDateString = dateFormatter.string(from: startDate) { - URLQueryItem( - name: "startDate", - value: startDateString - ) - } + URLQueryItem( + name: "startDate", + value: dateFormatter.string(from: startDate) + ) if let pageSize = pageSize { URLQueryItem( diff --git a/NOICommunityLib/Sources/EventShortClientLive/Live.swift b/NOICommunityLib/Sources/EventShortClientLive/Live.swift index e1b1a7a..1513706 100644 --- a/NOICommunityLib/Sources/EventShortClientLive/Live.swift +++ b/NOICommunityLib/Sources/EventShortClientLive/Live.swift @@ -77,7 +77,7 @@ extension EventShortClient { return urlSession .dataTaskPublisher(for: urlComponents.url!) - .map { data, _ in data } + .map(\.data) .decode( type: EventShortListResponse.self, decoder: eventsJsonDecoder @@ -96,7 +96,7 @@ extension EventShortClient { return URLSession.shared .dataTaskPublisher(for: urlComponents.url!) - .map { data, _ in data } + .map(\.data) .decode( type: [String:String].self, decoder: eventsJsonDecoder diff --git a/NOICommunityLib/Sources/EventShortTypesClientLive/Live.swift b/NOICommunityLib/Sources/EventShortTypesClientLive/Live.swift index 946d616..535e458 100644 --- a/NOICommunityLib/Sources/EventShortTypesClientLive/Live.swift +++ b/NOICommunityLib/Sources/EventShortTypesClientLive/Live.swift @@ -34,7 +34,7 @@ extension EventShortTypesClient { filters: { urlSession .dataTaskPublisher(for: requestURL()) - .map { data, _ in data } + .map(\.data) .decode( type: [EventsFilter].self, decoder: jsonDecoder diff --git a/NOICommunityLib/Sources/PeopleClientLive/Live.swift b/NOICommunityLib/Sources/PeopleClientLive/Live.swift index 1a1e3bd..c6ffd02 100644 --- a/NOICommunityLib/Sources/PeopleClientLive/Live.swift +++ b/NOICommunityLib/Sources/PeopleClientLive/Live.swift @@ -30,10 +30,10 @@ extension PeopleClient { "Authorization": "Bearer \(accessToken)", "Accept": "application/json" ] - + return urlSession .dataTaskPublisher(for: urlRequest) - .map { data, _ in data } + .map(\.data) .decode( type: PeopleResponse.self, decoder: JSONDecoder() @@ -51,7 +51,7 @@ extension PeopleClient { return urlSession .dataTaskPublisher(for: urlRequest) - .map { data, _ in data } + .map(\.data) .decode( type: CompanyResponse.self, decoder: JSONDecoder()