diff --git a/pkg/providers/telegram/telegram.go b/pkg/providers/telegram/telegram.go index 54edba9..e1bd52c 100644 --- a/pkg/providers/telegram/telegram.go +++ b/pkg/providers/telegram/telegram.go @@ -2,6 +2,7 @@ package telegram import ( "fmt" + "strings" "github.com/containrrr/shoutrrr" "github.com/pkg/errors" @@ -48,6 +49,7 @@ func (p *Provider) Send(message, CliFormat string) error { pr.TelegramParseMode = "None" } url := fmt.Sprintf("telegram://%s@telegram?channels=%s&parsemode=%s", pr.TelegramAPIKey, pr.TelegramChatID, pr.TelegramParseMode) + msg = strings.ReplaceAll(msg, "_", "\\_") err := shoutrrr.Send(url, msg) if err != nil { err = errors.Wrap(err, fmt.Sprintf("failed to send telegram notification for id: %s ", pr.ID))