Skip to content

Commit 521673d

Browse files
committed
Updated NetworkingService
1 parent 37f8111 commit 521673d

File tree

4 files changed

+8
-8
lines changed

4 files changed

+8
-8
lines changed

SkyWizard-SwiftUI.xcodeproj/project.xcworkspace/xcshareddata/swiftpm/Package.resolved

Lines changed: 3 additions & 3 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

SkyWizardAPI/Package.swift

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -25,7 +25,7 @@ let package = Package(
2525
)
2626
],
2727
dependencies: [
28-
.package(url: "https://github.com/hishd/NetworkingService", .upToNextMajor(from: "1.0.4")),
28+
.package(url: "https://github.com/hishd/NetworkingService", .upToNextMajor(from: "1.0.7")),
2929
],
3030
targets: [
3131
// Targets are the basic building blocks of a package, defining a module or a test suite.

SkyWizardAPI/Sources/SkyWizardService/Geocoding/GeocodingServiceRemote.swift

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -23,8 +23,8 @@ public final class GeocodingServiceRemote: GeocodingService {
2323
//Checking task cancellation
2424
try Task.checkCancellation()
2525

26-
let task = await dataTransferService.request(with: GeocodingEndpoints.getGeocoding(latitude: location.latitude, longitude: location.longitude))
27-
let value: GeocodeData = try await task.value.mapToGeocodeResult()
26+
let result: GeocodeResultDTO = try await dataTransferService.request(with: GeocodingEndpoints.getGeocoding(latitude: location.latitude, longitude: location.longitude))
27+
let value: GeocodeData = try result.mapToGeocodeResult()
2828
return value
2929
}
3030
}

SkyWizardAPI/Sources/SkyWizardService/Weather/WeatherServiceRemote.swift

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -22,8 +22,8 @@ public final class WeatherServiceRemote: WeatherService {
2222
//Checking task cancellation
2323
try Task.checkCancellation()
2424

25-
let task = await dataTransferService.request(with: WeatherEndpoints.getWeather(latitude: location.latitude, longitude: location.longitude))
26-
return try await task.value
25+
let result: WeatherData = try await dataTransferService.request(with: WeatherEndpoints.getWeather(latitude: location.latitude, longitude: location.longitude))
26+
return result
2727
}
2828

2929
public func getWeatherType(for current: WeatherData.CurrentWeatherData) -> CurrentWeatherType {

0 commit comments

Comments
 (0)