Skip to content

Commit

Permalink
chore: remove unnecessary vars
Browse files Browse the repository at this point in the history
  • Loading branch information
Zaptross committed Jan 2, 2024
1 parent ce10514 commit 625d0d9
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 16 deletions.
5 changes: 0 additions & 5 deletions example.env
Original file line number Diff line number Diff line change
Expand Up @@ -6,11 +6,6 @@ REACTROLES_SLASHCOMMANDS=
DISCORD_TOKEN=
DISCORD_APPID=

# Roles that give user permissions to use commands
DISCORD_ROLEADDROLEID=
DISCORD_ROLEREMOVEROLEID=
DISCORD_ROLECHANNEL=

# Postgres Config
POSTGRES_USER=
POSTGRES_PASSWORD=
Expand Down
14 changes: 3 additions & 11 deletions internal/dgclient/dgclient.go
Original file line number Diff line number Diff line change
Expand Up @@ -11,13 +11,9 @@ import (
)

type DiscordGoClientParams struct {
Token string
RoleMessage string
RoleChannel string
RoleAddRoleID string
RoleRemoveRoleID string
AppID string
DB *pgdb.ReactRolesDatabase `ignored:"true"`
Token string
AppID string
DB *pgdb.ReactRolesDatabase `ignored:"true"`
}

type DiscordGoClient struct {
Expand All @@ -26,10 +22,6 @@ type DiscordGoClient struct {
}

func GetClient(params DiscordGoClientParams) *DiscordGoClient {
if params.RoleChannel == "" {
log.Fatal("Role channel not set in client params")
}

dg, err := discordgo.New("Bot " + params.Token)
if err != nil {
log.Fatal(err)
Expand Down

0 comments on commit 625d0d9

Please sign in to comment.