mirror of https://github.com/caronc/apprise
slight refactoring
parent
ac5aa5a333
commit
bcfeed9519
|
@ -108,7 +108,6 @@ class NotifySpike(NotifyBase):
|
||||||
|
|
||||||
def send(self, body, title="", notify_type=NotifyType.INFO, **kwargs):
|
def send(self, body, title="", notify_type=NotifyType.INFO, **kwargs):
|
||||||
"""Send Spike.sh Notification."""
|
"""Send Spike.sh Notification."""
|
||||||
self.throttle()
|
|
||||||
|
|
||||||
payload = {
|
payload = {
|
||||||
"message": title if title else body,
|
"message": title if title else body,
|
||||||
|
@ -120,6 +119,9 @@ class NotifySpike(NotifyBase):
|
||||||
"Content-Type": "application/json",
|
"Content-Type": "application/json",
|
||||||
}
|
}
|
||||||
|
|
||||||
|
# Always call throttle before any remote server i/o is made
|
||||||
|
self.throttle()
|
||||||
|
|
||||||
try:
|
try:
|
||||||
response = requests.post(
|
response = requests.post(
|
||||||
self.webhook_url,
|
self.webhook_url,
|
||||||
|
|
Loading…
Reference in New Issue