Skip to content

Commit 8876033

Browse files
committed
add error log for wrong format_type
1 parent aa3fb8b commit 8876033

File tree

1 file changed

+3
-0
lines changed

1 file changed

+3
-0
lines changed

redditbot/subscriptions.go

+3
Original file line numberDiff line numberDiff line change
@@ -214,6 +214,9 @@ func (b *Bot) sendPost(sub Subscription, post RedditPost) bool {
214214
webhookMessageCreate = discord.WebhookMessageCreate{
215215
Content: fmt.Sprintf("[%s](%s%s)", post.Title, proxy, post.Permalink),
216216
}
217+
default:
218+
slog.Error("unknown format type", slog.String("format_type", string(sub.FormatType)))
219+
return true
217220
}
218221

219222
if sub.RoleID != 0 {

0 commit comments

Comments
 (0)