Skip to content

Commit 0d16b1c

Browse files
committed
Add fields to \all endpoint
The API provider is now requiring requests for this endpoint to specify upto 10 fields (https://gitlab.com/restcountries/restcountries/-/issues/265)
1 parent 87283f7 commit 0d16b1c

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

CountriesSwiftUI/Repositories/WebAPI/CountriesWebRepository.swift

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -49,7 +49,7 @@ extension RealCountriesWebRepository.API: APICall {
4949
var path: String {
5050
switch self {
5151
case .allCountries:
52-
return "/all"
52+
return "/all?fields=name,translations,population,flag,alpha3Code"
5353
case let .countryDetails(countryName):
5454
let encodedName = countryName.addingPercentEncoding(withAllowedCharacters: .urlQueryAllowed)
5555
return "/name/\(encodedName ?? countryName)"

0 commit comments

Comments
 (0)