mirror of
https://github.com/suyiiyii/nonebot-bison.git
synced 2025-06-04 02:26:11 +08:00
15 lines
397 B
Python
15 lines
397 B
Python
import typing
|
|
if typing.TYPE_CHECKING:
|
|
import sys
|
|
sys.path.append('./src/plugins')
|
|
import nonebot_hk_reporter
|
|
import nonebot
|
|
|
|
nonebot.init()
|
|
plugins = nonebot.load_plugins('src/plugins')
|
|
plugin = list(filter(lambda x: x.name == 'nonebot_hk_reporter', plugins))[0]
|
|
if typing.TYPE_CHECKING:
|
|
plugin_module : nonebot_hk_reporter = plugin.module
|
|
else:
|
|
plugin_module = plugin.module
|