diff options
| author | Anhgelus Morhtuuzh <william@herges.fr> | 2026-01-22 21:53:29 +0100 |
|---|---|---|
| committer | Anhgelus Morhtuuzh <william@herges.fr> | 2026-01-22 21:53:29 +0100 |
| commit | 3e65b4f6281ddc4039a27a62428db8a95ffc3677 (patch) | |
| tree | b1005f908be45aa47da48b604f3863ef23a3d7ea /config/channel.go | |
| parent | 8255a2e51454049f3ac1532f6e1125f528691c37 (diff) | |
refactor(): completely remove old gokord and finish to update everything to use contexts
Diffstat (limited to 'config/channel.go')
| -rw-r--r-- | config/channel.go | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/config/channel.go b/config/channel.go index 6086f09..4650e15 100644 --- a/config/channel.go +++ b/config/channel.go @@ -20,13 +20,13 @@ const ( ) func HandleModifyFallbackChannel(ctx context.Context, dg bot.Session, i *interaction.MessageComponent) bool { - cfg := GetGuildConfig(i.GuildID) + cfg := GetGuildConfig(ctx, i.GuildID) var channelID string if len(i.Data.Values) > 0 { channelID = i.Data.Values[0] } cfg.FallbackChannel = channelID - err := cfg.Save() + err := cfg.Save(ctx) if err != nil { bot.Logger(ctx).Error("saving fallback channel", "error", err) return false @@ -35,9 +35,9 @@ func HandleModifyFallbackChannel(ctx context.Context, dg bot.Session, i *interac } func HandleModifyDisChannel(ctx context.Context, dg bot.Session, i *interaction.MessageComponent) bool { - cfg := GetGuildConfig(i.GuildID) + cfg := GetGuildConfig(ctx, i.GuildID) cfg.DisabledChannels = strings.Join(i.Data.Values, ";") - err := cfg.Save() + err := cfg.Save(ctx) if err != nil { bot.Logger(ctx).Error("unable to save disabled channel", "error", err) return false |
