mirror of
https://github.com/yulinfeng000/blive.git
synced 2025-03-25 16:50:53 +08:00
add deprecated warn info
This commit is contained in:
parent
46b8078bc1
commit
2ddb6ae327
@ -1,3 +1,4 @@
|
||||
import warnings
|
||||
import json
|
||||
import asyncio
|
||||
from typing import List, Union
|
||||
@ -38,6 +39,7 @@ class BLiver(AsyncIOEventEmitter):
|
||||
self.aio_session = aiohttp.ClientSession()
|
||||
|
||||
def register_handler(self, event: Union[Events, List[Events]], handler):
|
||||
warnings.warn("`register_handler` is deprecated function please use `on`",DeprecationWarning)
|
||||
self.on(event, handler)
|
||||
|
||||
async def heartbeat(self):
|
||||
|
Loading…
Reference in New Issue
Block a user