Skip to content

Commit

Permalink
Merge pull request #43 from makermelissa/master
Browse files Browse the repository at this point in the history
Fix bug where if category is out of bounds it was crashing
  • Loading branch information
makermelissa authored Dec 11, 2019
2 parents 444df22 + beb7638 commit 26325f6
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions adafruit_ble/services/apple.py
Original file line number Diff line number Diff line change
Expand Up @@ -165,6 +165,8 @@ def __str__(self):
category = None
if self.category_id < len(NOTIFICATION_CATEGORIES):
category = NOTIFICATION_CATEGORIES[self.category_id]
else:
category = "Reserved"

if self.silent:
flags.append("silent")
Expand Down

0 comments on commit 26325f6

Please sign in to comment.