Skip to content

Commit

Permalink
Address issue where exit_callback is sent before master channel is re…
Browse files Browse the repository at this point in the history
…ady. (#21)
  • Loading branch information
blueset committed Jun 17, 2018
1 parent e6f7d63 commit 0a2994f
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions efb_wechat_slave/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -257,6 +257,9 @@ def master_qr_code(self, uuid, status, qrcode=None):
coordinator.send_message(msg)

def exit_callback(self):
# Don't send prompt if there's nowhere to send.
if not coordinator.master:
return
self.logger.debug('Calling exit callback...')
if self._stop_polling_event.is_set():
return
Expand Down

0 comments on commit 0a2994f

Please sign in to comment.