Skip to content

Commit

Permalink
Merge pull request #45 from londonhackspace/fix_doorbot_notifications
Browse files Browse the repository at this point in the history
Non-subscribers should not return a name
  • Loading branch information
jasiek committed Feb 25, 2016
2 parents 6ea5eb9 + 9bb35b2 commit 72c20d7
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion listeners/carddb.py
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ def __init__(self, filename):
def nickForCard(self, card_serial):
self.maybeRefresh()
for entry in self.db:
if card_serial in entry['cards']:
if card_serial in entry['cards'] and entry['subscribed'] == True:
return entry['nick']
return None

Expand Down

0 comments on commit 72c20d7

Please sign in to comment.