Skip to content

Commit

Permalink
Check for geocoding_providers is empty.
Browse files Browse the repository at this point in the history
  • Loading branch information
wlorenzetti committed Nov 8, 2023
1 parent c9e04b1 commit 2218022
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion g3w-admin/core/api/serializers.py
Original file line number Diff line number Diff line change
Expand Up @@ -260,7 +260,7 @@ def to_representation(self, instance):
ret['mapcontrols'] = {}
for mapcontrol in instance.mapcontrols.all():
options = {}
if mapcontrol.name in ('nominatim', 'geolocation'):
if mapcontrol.name in ('nominatim', 'geolocation') and self.project.geocoding_providers:
for gp in json.loads(self.project.geocoding_providers):
if gp in settings.GEOCONDING_PROVIDERS:
options.update({
Expand Down

0 comments on commit 2218022

Please sign in to comment.