1
0
mirror of https://github.com/moparisthebest/SickRage synced 2024-11-15 22:05:02 -05:00

Add SickRage to notification title

This commit is contained in:
rpluto 2014-05-07 19:44:43 +01:00
parent 704281ab58
commit c9cc36fbc6

View File

@ -31,7 +31,7 @@ API_URL = "https://new.boxcar.io/api/notifications"
class Boxcar2Notifier: class Boxcar2Notifier:
def test_notify(self, accesstoken, title="Test"): def test_notify(self, accesstoken, title="SickRage : Test"):
return self._sendBoxcar2("This is a test notification from SickBeard", title, accesstoken) return self._sendBoxcar2("This is a test notification from SickBeard", title, accesstoken)
def _sendBoxcar2(self, msg, title, accesstoken): def _sendBoxcar2(self, msg, title, accesstoken):
@ -46,12 +46,13 @@ class Boxcar2Notifier:
""" """
# build up the URL and parameters # build up the URL and parameters
#more info goes here - https://boxcar.uservoice.com/knowledgebase/articles/306788-how-to-send-your-boxcar-account-a-notification
msg = msg.strip() msg = msg.strip()
curUrl = API_URL curUrl = API_URL
data = urllib.urlencode({ data = urllib.urlencode({
'user_credentials': accesstoken, 'user_credentials': accesstoken,
'notification[title]': title, 'notification[title]': "SickRage : " + title,
'notification[long_message]': msg, 'notification[long_message]': msg,
'notification[sound]': "bird-1" 'notification[sound]': "bird-1"
}) })