Skip to content

Commit

Permalink
Add default parameter for administrative areas
Browse files Browse the repository at this point in the history
  • Loading branch information
DeanElliott96 authored and cgsunkel committed Jun 21, 2024
1 parent 839705b commit ba2c16b
Showing 1 changed file with 1 addition and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ import { metadata } from '../../../lib/urls'

export default function useAdministrativeAreaLookup() {
return async function findAreaByCountryId(countryId = undefined) {
const { data } = await axios(metadata.administrativeArea())
const { data } = await axios(`${metadata.administrativeArea()}?_=0`)
return countryId ? filterAreaDataByCountry(data, countryId) : data
}
}
Expand Down

0 comments on commit ba2c16b

Please sign in to comment.