Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@
static func map(from domain: CarDomain) -> CarModel {
CarModel(
number: domain.number,
driver: DriverMapper.map(domain: domain.driver)
driver: DriverMapper.map(from: domain.driver)
)
}

Expand Down Expand Up @@ -68,4 +68,4 @@
)
}
}

Check warning on line 71 in Sources/PodiumRequestsClient/Models/Mappers/CarMapper.swift

View workflow job for this annotation

GitHub Actions / Lint Code

Trailing Newline (trailing_newline)

Files should have a single trailing newline
14 changes: 7 additions & 7 deletions Sources/PodiumRequestsClient/Models/Mappers/DriverMapper.swift
Original file line number Diff line number Diff line change
Expand Up @@ -9,14 +9,14 @@ import Foundation

enum DriverMapper {
/// Map a `DriverDomain` into a `DriverDomain`.
static func map(domain from: DriverDomain) -> DriverModel {
static func map(from domain: DriverDomain) -> DriverModel {
DriverModel(
firstname: from.firstname,
lastname: from.lastname,
acronym: from.acronym,
number: from.number,
team: TeamMapper.map(from: from.team),
image: from.image
firstname: domain.firstname,
lastname: domain.lastname,
acronym: domain.acronym,
number: domain.number,
team: TeamMapper.map(from: domain.team),
image: domain.image
)
}
}
Expand Down
4 changes: 2 additions & 2 deletions Sources/PodiumRequestsClient/RequestsClient.swift
Original file line number Diff line number Diff line change
Expand Up @@ -212,7 +212,7 @@
type: [DriverDomain].self
)

return domain.map { DriverMapper.map(domain: $0) }
return domain.map { DriverMapper.map(from: $0) }
}

/// Retrieves a specific driver by ID from a session.
Expand All @@ -231,7 +231,7 @@
type: DriverDomain.self
)

return DriverMapper.map(domain: domain)
return DriverMapper.map(from: domain)
}

/// Retrieves all the weather updates for a given session.
Expand All @@ -253,7 +253,7 @@

return domain.map { WeatherMapper.map(from: $0) }
}

Check warning on line 256 in Sources/PodiumRequestsClient/RequestsClient.swift

View workflow job for this annotation

GitHub Actions / Lint Code

Trailing Whitespace (trailing_whitespace)

Lines should not have trailing whitespace
public func getAllIntervals(
sessionKey: Int,
chunk: Chunk? = nil
Expand All @@ -263,7 +263,7 @@
type: [IntervalDomain].self,
chunk: chunk
)

Check warning on line 266 in Sources/PodiumRequestsClient/RequestsClient.swift

View workflow job for this annotation

GitHub Actions / Lint Code

Trailing Whitespace (trailing_whitespace)

Lines should not have trailing whitespace
return domain.map { IntervalMapper.map(from: $0) }
}
}
Expand Down
Loading