made getting tags working

This commit is contained in:
2024-04-04 20:14:47 +02:00
parent b85d9d5294
commit 68a99fbb10
4 changed files with 75 additions and 54 deletions

23
main.go
View File

@@ -15,7 +15,6 @@ import (
"github.com/disgoorg/disgo"
"github.com/disgoorg/disgo/bot"
"github.com/disgoorg/disgo/discord"
"github.com/disgoorg/disgo/gateway"
"github.com/joho/godotenv"
"github.com/sirupsen/logrus"
@@ -23,9 +22,7 @@ import (
)
var (
client bot.Client
app *discord.Application
db *sql.DB
db *sql.DB
)
func main() {
@@ -47,13 +44,15 @@ func main() {
),
),
bot.WithEventListenerFunc(ready),
//bot.WithEventListenerFunc(applicationCommandInteractionCreate),
//bot.WithEventListenerFunc(autocompleteInteractionCreate),
//bot.WithEventListenerFunc(componentInteractionCreate),
//bot.WithEventListenerFunc(modalSubmitInteractionCreate),
//bot.WithEventListenerFunc(messageCreate),
//bot.WithEventListenerFunc(messageDelete),
//bot.WithEventListenerFunc(guildMemberJoin),
bot.WithEventListenerFunc(applicationCommandInteractionCreate),
bot.WithEventListenerFunc(autocompleteInteractionCreate),
bot.WithEventListenerFunc(componentInteractionCreate),
bot.WithEventListenerFunc(modalSubmitInteractionCreate),
/*
bot.WithEventListenerFunc(messageCreate),
bot.WithEventListenerFunc(messageDelete),
bot.WithEventListenerFunc(guildMemberJoin),
*/
)
if err != nil {
logrus.Fatal("error creating Discord session,", err)
@@ -66,7 +65,7 @@ func main() {
logrus.Error("error opening connection,", err)
return
}
app, err = client.Rest().GetCurrentApplication()
app, err := client.Rest().GetCurrentApplication()
if err != nil {
logrus.Error(err)
}