def load(): logger.info(f"Load {module_name} module") dp.register_message_handler(notif_cmd, lambda msg: msg.text.lower() == "notif") dp.register_callback_query_handler( notif_query, posts_cb.filter(action=["toggle", "time", "cooldown"])) dp.register_message_handler(await_cmd, lambda msg: have_await_cmd(msg)) modules_active.append(module_name)
def load(): logger.info(f"Load {module_name} module") dp.register_message_handler(get_id, commands="getid") dp.register_message_handler(get_logs, commands="getlogs") dp.register_message_handler(get_db, commands="getdb") dp.register_message_handler(eval_cmd, commands="eval") dp.register_errors_handler(errors) modules_active.append(module_name)
def load(): logger.info(f"Load {module_name} module") dp.register_message_handler(edt_cmd, lambda msg: msg.text.lower() == "edt") dp.register_inline_handler(inline_edt) dp.register_callback_query_handler(edt_query, posts_cb.filter(action=["day", "next", "week", "next week"])) dp.register_message_handler(edt_await, lambda msg: msg.text.lower() == "setedt") dp.register_message_handler(await_cmd, lambda msg: have_await_cmd(msg), content_types=[ContentType.TEXT, ContentType.PHOTO]) dp.register_message_handler(edt_geturl, commands="getedt") modules_active.append(module_name)
def load(): logger.info(f"Load {module_name} module") dp.register_message_handler(kfet, lambda msg: msg.text.lower() == "kfet") dp.register_message_handler(kfet_set, lambda msg: msg.text.lower() == "setkfet") dp.register_message_handler(await_cmd, lambda msg: have_await_cmd(msg)) modules_active.append(module_name)
def load(): logger.info(f"Load {module_name} module") dp.register_message_handler(load_cmd, commands="load") dp.register_message_handler(unload_cmd, commands="unload") modules_active.append(module_name)
def load(): logger.info(f"Load {module_name} module") dp.register_message_handler(start, commands="start") dp.register_message_handler(help_cmd, commands="help") modules_active.append(module_name)