set as HTML mode
This commit is contained in:
parent
f72631e072
commit
9a0cc9c1c3
|
|
@ -17,6 +17,7 @@ type (
|
|||
// TelegramPayload represents
|
||||
TelegramPayload struct {
|
||||
Message string `json:"text"`
|
||||
ParseMode string `json:"parse_mode"`
|
||||
}
|
||||
)
|
||||
|
||||
|
|
@ -25,6 +26,7 @@ func (p *TelegramPayload) SetSecret(_ string) {}
|
|||
|
||||
// JSONPayload Marshals the TelegramPayload to json
|
||||
func (p *TelegramPayload) JSONPayload() ([]byte, error) {
|
||||
p.ParseMode = "HTML"
|
||||
data, err := json.MarshalIndent(p, "", " ")
|
||||
if err != nil {
|
||||
return []byte{}, err
|
||||
|
|
|
|||
Loading…
Reference in New Issue
Block a user