Skip to content

Commit

Permalink
Merge pull request #40 from melvinkcx/features/null_handler
Browse files Browse the repository at this point in the history
add nullhandler
  • Loading branch information
melvinkcx authored Nov 22, 2022
2 parents ba27032 + 11b664c commit 0219f48
Showing 1 changed file with 17 additions and 0 deletions.
17 changes: 17 additions & 0 deletions fastapi_events/handlers/null.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
from typing import Iterable

from fastapi_events.handlers.base import BaseEventHandler
from fastapi_events.typing import Event


class NullHandler(BaseEventHandler):
"""
NullHandler
a handler that does nothing.
can be used as a stub when a handler is expected.
"""
async def handle(self, event: Event) -> None:
...

async def handle_many(self, events: Iterable[Event]) -> None:
...

0 comments on commit 0219f48

Please sign in to comment.