From 85dfe9f677141f895eee70362a2713ad61afe4a9 Mon Sep 17 00:00:00 2001 From: unintendedfraud Date: Sat, 26 Aug 2023 12:46:25 +0200 Subject: [PATCH] f --- main.go | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/main.go b/main.go index 43c9ca2..dab95f3 100644 --- a/main.go +++ b/main.go @@ -20,7 +20,8 @@ func main() { fmt.Println("env: ", env) - dgclient, err := discordbot.New("Bot " + env.Token) + discordToken := fmt.Sprintf("Bot %s", env.Token) + dgclient, err := discordbot.New(discordToken) if err != nil { panic(fmt.Errorf("failed to create discord client: %s", err.Error())) } @@ -37,7 +38,7 @@ func main() { client := tempest.CreateClient(tempest.ClientOptions{ ApplicationId: env.AppID, PublicKey: env.PublicKey, - Token: env.Token, + Token: discordToken, PreCommandExecutionHandler: func(itx tempest.CommandInteraction) *tempest.ResponseData { log.Printf("running [%s] slash command", itx.Data.Name) return nil