Skip to content

Commit

Permalink
Fix error when MoveToFort called from handle_soft_ban.py (#3500)
Browse files Browse the repository at this point in the history
* Fix error when MoveToFort called from handle_soft_ban.py

* Added myself to CONTRIBUTORS.md
  • Loading branch information
cmezh authored and solderzzc committed Aug 11, 2016
1 parent 9ccadcd commit 847154d
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 3 deletions.
1 change: 1 addition & 0 deletions CONTRIBUTORS.md
Original file line number Diff line number Diff line change
Expand Up @@ -61,3 +61,4 @@
* JaapMoolenaar
* eevee-github
* g0vanish
* cmezh
10 changes: 7 additions & 3 deletions pokemongo_bot/cell_workers/move_to_fort.py
Original file line number Diff line number Diff line change
Expand Up @@ -13,9 +13,13 @@ class MoveToFort(BaseTask):

def initialize(self):
self.lure_distance = 0
self.lure_attraction = self.config.get("lure_attraction", True)
self.lure_max_distance = self.config.get("lure_max_distance", 2000)
self.ignore_item_count = self.config.get("ignore_item_count", False)
if self.config:
self.lure_attraction = self.config.get("lure_attraction", True)
self.lure_max_distance = self.config.get("lure_max_distance", 2000)
self.ignore_item_count = self.config.get("ignore_item_count", False)
else:
self.lure_attraction = None
self.ignore_item_count = True

def should_run(self):
has_space_for_loot = self.bot.has_space_for_loot()
Expand Down

0 comments on commit 847154d

Please sign in to comment.