Skip to content

Commit

Permalink
chore: bump version
Browse files Browse the repository at this point in the history
  • Loading branch information
muety committed Aug 28, 2023
1 parent 5d86417 commit d2af7c6
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
2 changes: 1 addition & 1 deletion config/version.txt
Original file line number Diff line number Diff line change
@@ -1 +1 @@
4.1.0
4.1.1
4 changes: 2 additions & 2 deletions handlers/message.go
Original file line number Diff line number Diff line change
Expand Up @@ -83,10 +83,10 @@ func (h *MessageHandler) ServeHTTP(w http.ResponseWriter, r *http.Request) {
} else if err := resolver.Resolve(recipientId, m, &p); err != nil {
statusCode := parseStatusCode(err, http.StatusInternalServerError)

if statusCode == 403 {
if statusCode == http.StatusForbidden {
// user has probably blocked the bot -> invalidate token
h.userService.InvalidateToken(token)
log.Printf("invalidating token '%s' for chat '%s', because got 403 from telegram", token, recipientId)
log.Printf("invalidating token '%s' for chat '%s', because got 403 from telegram\n", token, recipientId)
err = errors.New("error: got 403 from telegram, invalidating your token, text the bot to generate a new one")
}

Expand Down

0 comments on commit d2af7c6

Please sign in to comment.