mirror of
https://github.com/caronc/apprise.git
synced 2024-11-22 08:04:02 +01:00
Fix Pushover parsing of integer priorities (#598)
This commit is contained in:
parent
aaf0aea668
commit
62edc52871
@ -571,14 +571,14 @@ class NotifyPushover(NotifyBase):
|
|||||||
'h': PushoverPriority.HIGH,
|
'h': PushoverPriority.HIGH,
|
||||||
'e': PushoverPriority.EMERGENCY,
|
'e': PushoverPriority.EMERGENCY,
|
||||||
|
|
||||||
# Entries to additionally support (so more like PushOver's API
|
# Entries to additionally support (so more like PushOver's API)
|
||||||
'-2': PushoverPriority.LOW,
|
'-2': PushoverPriority.LOW,
|
||||||
'-1': PushoverPriority.MODERATE,
|
'-1': PushoverPriority.MODERATE,
|
||||||
'0': PushoverPriority.NORMAL,
|
'0': PushoverPriority.NORMAL,
|
||||||
'1': PushoverPriority.HIGH,
|
'1': PushoverPriority.HIGH,
|
||||||
'2': PushoverPriority.EMERGENCY,
|
'2': PushoverPriority.EMERGENCY,
|
||||||
}
|
}
|
||||||
priority = results['qsd']['priority'][0].lower()
|
priority = results['qsd']['priority'].lower()
|
||||||
results['priority'] = \
|
results['priority'] = \
|
||||||
next((
|
next((
|
||||||
v for k, v in _map.items() if priority.startswith(k)),
|
v for k, v in _map.items() if priority.startswith(k)),
|
||||||
|
Loading…
Reference in New Issue
Block a user