Skip to content

Commit

Permalink
fixed #18
Browse files Browse the repository at this point in the history
  • Loading branch information
itskekoff committed May 15, 2023
1 parent a896b21 commit 7c4e908
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions main.py
Original file line number Diff line number Diff line change
Expand Up @@ -353,12 +353,12 @@ async def on_message(message: discord.Message):
async def copy(ctx: commands.Context, server_id: int = None):
global cloner_instances, register_on_message
await ctx.message.delete()
guild: discord.Guild = bot.get_guild(id=server_id) if server_id else ctx.message.guild
guild: discord.Guild = bot.get_guild(server_id) if server_id else ctx.message.guild
if guild is None and server_id is None:
return

print("* Creating server... | " + guild.name)
new_guild: discord.Guild = await bot.create_guild(name=name_syntax.replace("%original", guild.name))
new_guild: discord.Guild = await bot.create_guild(name_syntax.replace("%original", guild.name))
cloner: ServerCopy = ServerCopy(from_guild=guild, to_guild=new_guild,
delay=clone_delay, webhook_delay=messages_delay)
cloner_instances.append(cloner)
Expand All @@ -380,5 +380,5 @@ async def copy(ctx: commands.Context, server_id: int = None):
print("* Done")


Updater("1.2.8")
Updater("1.2.9")
bot.run(token)

0 comments on commit 7c4e908

Please sign in to comment.