add: webhook

This commit is contained in:
h z
2025-03-17 13:54:53 +00:00
parent acb1e2260f
commit 864b78641b
23 changed files with 473 additions and 43 deletions

View File

@@ -0,0 +1,20 @@
from events import MARKDOWN_CREATED_EVENT, markdown_created
from events.WebhookEventHandlers import auto_instantiate
from events.WebhookEventHandlers.MarkdownWebhookEventHandlers import MarkdownWebhookEventHandler
from misc import Singleton
@auto_instantiate
class MarkdownCreatedWebhookEventHandler(MarkdownWebhookEventHandler, Singleton):
def __init__(self):
if getattr(self, "_initialized", False):
return
super().__init__(MARKDOWN_CREATED_EVENT)
markdown_created.connect(self)
self._initialized = True