diff --git a/main.py b/main.py index 57e06ea..80e38ba 100644 --- a/main.py +++ b/main.py @@ -93,13 +93,14 @@ async def delivery(ctx, async def changeSheetUrl(ctx, url:discord.Option(discord.SlashCommandOptionType.string, description="the new URL") ): + global gsheetToken await ctx.defer() try: with open("sheet.token",'w') as f: f.write(url) await ctx.followup.send(f"URL has been set") - global gsheetToken = readToken("sheet.token") + gsheetToken = readToken("sheet.token") except Exception as e: await ctx.followup.send(f"something shat the bed")