New sync method

This commit is contained in:
Cal Corum 2024-12-18 09:59:39 -06:00
parent 3d41ec1662
commit 07fcbca866

View File

@ -114,6 +114,14 @@ class Owner(commands.Cog):
ctx.bot.tree.clear_commands(guild=ctx.guild) ctx.bot.tree.clear_commands(guild=ctx.guild)
await ctx.bot.tree.sync(guild=ctx.guild) await ctx.bot.tree.sync(guild=ctx.guild)
synced = [] synced = []
elif spec == '!':
await ctx.bot.tree.sync()
ctx.bot.tree.copy_global_to(guild=ctx.guild)
await ctx.bot.tree.sync(guild=ctx.guild)
ctx.bot.tree.clear_commands(guild=ctx.guild)
synced = await ctx.bot.tree.sync(guild=ctx.guild)
else: else:
synced = await ctx.bot.tree.sync() synced = await ctx.bot.tree.sync()