mirror of
https://github.com/inventree/InvenTree.git
synced 2025-04-30 20:46:47 +00:00
fix init checks
This commit is contained in:
parent
7974559ead
commit
e678e8bd05
@ -20,7 +20,7 @@ class NotificationMethod:
|
||||
|
||||
def __init__(self, obj, entry_name, receivers) -> None:
|
||||
# check if a sending fnc is defined
|
||||
if ('send' not in self) and ('send_bulk' not in self):
|
||||
if (not hasattr(self, 'send')) and (not hasattr(self, 'send_bulk')):
|
||||
raise NotImplementedError('A NotificationMethod must either define a `send` or a `send_bulk` method')
|
||||
|
||||
# define arguments
|
||||
|
Loading…
x
Reference in New Issue
Block a user