/init -> /reset

This commit is contained in:
bursa-pastoris 2023-06-11 15:31:02 +02:00
parent b3f4e24743
commit 26e76cde2f
2 changed files with 6 additions and 6 deletions

View File

@ -151,7 +151,7 @@ async def help(update, context):
# Admin commands # Admin commands
adm_header = _('*Additional commands for bot admins*') adm_header = _('*Additional commands for bot admins*')
adm_help = { adm_help = {
_('init'):_('reinitialize the bot\. This updates inline suggestions' _('reset'):_('reset the bot\. This updates inline suggestions'
' and purges /epiphony cached files\.'), ' and purges /epiphony cached files\.'),
_('stop'):_('stop Albatrobot\. To be used _only_ in case of emergency:' _('stop'):_('stop Albatrobot\. To be used _only_ in case of emergency:'
' restarting the bot after this command is used requires direct' ' restarting the bot after this command is used requires direct'
@ -182,8 +182,8 @@ async def help(update, context):
) )
async def init(update, context): async def reset(update, context):
"""Initialize the bot.""" """Reset the bot."""
# Set commands suggestions # Set commands suggestions
commands=[BotCommand(_('christmas'),_('Get an image')), commands=[BotCommand(_('christmas'),_('Get an image')),
BotCommand(_('easter'),_('Get a citation')), BotCommand(_('easter'),_('Get a citation')),

View File

@ -43,7 +43,7 @@ application.add_handler(
albatrobot.unauthorized_user) albatrobot.unauthorized_user)
) )
application.add_handler( application.add_handler(
CommandHandler(['stop',_('stop'),'init',_('init')], CommandHandler(['stop',_('stop'),'reset',_('reset')],
albatrobot.unauthorized_user, albatrobot.unauthorized_user,
(~filters.User(ADMINS))) (~filters.User(ADMINS)))
) )
@ -64,8 +64,8 @@ application.add_handler(
albatrobot.help) albatrobot.help)
) )
application.add_handler( application.add_handler(
CommandHandler(['init',_('init')], CommandHandler(['reset',_('reset')],
albatrobot.init) albatrobot.reset)
) )
application.add_handler( application.add_handler(
CommandHandler(['legal',_('legal')], CommandHandler(['legal',_('legal')],