|
@ -1,15 +1,17 @@ |
|
|
|
|
|
import traceback |
|
|
|
|
|
|
|
|
from couchpotato.core.helpers.encoding import toUnicode |
|
|
from couchpotato.core.helpers.encoding import toUnicode |
|
|
from couchpotato.core.helpers.variable import getIdentifier |
|
|
from couchpotato.core.helpers.variable import getIdentifier |
|
|
from couchpotato.core.logger import CPLog |
|
|
from couchpotato.core.logger import CPLog |
|
|
from couchpotato.core.notifications.base import Notification |
|
|
from couchpotato.core.notifications.base import Notification |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
log = CPLog(__name__) |
|
|
log = CPLog(__name__) |
|
|
|
|
|
|
|
|
autoload = 'Webhook' |
|
|
autoload = 'Webhook' |
|
|
|
|
|
|
|
|
class Webhook(Notification): |
|
|
class Webhook(Notification): |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
def notify(self, message = '', data = None, listener = None): |
|
|
def notify(self, message = '', data = None, listener = None): |
|
|
if not data: data = {} |
|
|
if not data: data = {} |
|
|
|
|
|
|
|
|