Skip to content

Commit

Permalink
Fix issues with config keys in commit c7de979
Browse files Browse the repository at this point in the history
  • Loading branch information
nihalsid committed May 25, 2020
1 parent c7de979 commit 786bbc9
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions flathunter/hunter.py
Original file line number Diff line number Diff line change
Expand Up @@ -59,7 +59,7 @@ def hunt_flats(self, searchers, id_watch):
break

# calculate durations if enabled
if self.config.google_maps_api.enable:
if self.config["google_maps_api"]["enable"]:
durations = self.get_formatted_durations(self.config, address).strip()

message = self.config.get('message', "").format(
Expand All @@ -69,7 +69,7 @@ def hunt_flats(self, searchers, id_watch):
price=expose['price'],
url=expose['url'],
address=address,
durations="" if not self.config.google_maps_api.enable else durations).strip()
durations="" if not self.config["google_maps_api"]["enable"] else durations).strip()

# if no excludes, send messages
if len(self.excluded_titles) == 0:
Expand Down

0 comments on commit 786bbc9

Please sign in to comment.