mirror of
https://github.com/hrfee/jfa-go.git
synced 2025-01-03 23:10:11 +00:00
Compare commits
3 Commits
23800bb892
...
478b40d0ff
Author | SHA1 | Date | |
---|---|---|---|
478b40d0ff | |||
8b816dc725 | |||
81a58f628b |
@ -50,7 +50,7 @@ builds:
|
||||
flags:
|
||||
- -tags=tray
|
||||
ldflags:
|
||||
- -s -w -X main.version={{.Env.JFA_GO_VERSION}} -X main.commit={{.ShortCommit}} -X main.updater=binary
|
||||
- -s -w -X main.version={{.Env.JFA_GO_VERSION}} -X main.commit={{.ShortCommit}} -X main.updater=binary -H=windowsgui
|
||||
goos:
|
||||
- windows
|
||||
goarch:
|
||||
|
@ -148,7 +148,10 @@ func (t *TelegramDaemon) Send(message *Message, ID ...int64) error {
|
||||
if message.Markdown == "" {
|
||||
msg = tg.NewMessage(id, message.Text)
|
||||
} else {
|
||||
msg = tg.NewMessage(id, strings.ReplaceAll(message.Markdown, ".", "\\."))
|
||||
text := strings.ReplaceAll(message.Markdown, ".", "\\.")
|
||||
text = strings.ReplaceAll(text, "![", "[")
|
||||
text = strings.ReplaceAll(text, "!", "\\!")
|
||||
msg = tg.NewMessage(id, text)
|
||||
msg.ParseMode = "MarkdownV2"
|
||||
}
|
||||
_, err := t.bot.Send(msg)
|
||||
|
Loading…
Reference in New Issue
Block a user