Update to match tg API change

This commit is contained in:
Hamcha 2018-12-13 11:29:45 +01:00
parent a6e013ede5
commit 161dcee064
Signed by: hamcha
GPG key ID: A40413D21021EAEE
10 changed files with 130 additions and 41 deletions

View file

@ -43,13 +43,17 @@ func tz_message(broker *tg.Broker, update tg.APIMessage) {
if isCommand(update, "tz") { if isCommand(update, "tz") {
parts := strings.SplitN(*(update.Text), " ", 2) parts := strings.SplitN(*(update.Text), " ", 2)
if len(parts) < 2 { if len(parts) < 2 {
broker.SendTextMessage(update.Chat, "<b>Formato:</b> /tz <i>nome_timezone</i>", &update.MessageID) broker.SendTextMessage(update.Chat, "<b>Formato:</b> /tz <i>nome_timezone</i>", &tg.MessageOptions{
ReplyID: &update.MessageID,
})
return return
} }
loc, err := time.LoadLocation(parts[1]) loc, err := time.LoadLocation(parts[1])
if err != nil { if err != nil {
broker.SendTextMessage(update.Chat, "<b>Errore:</b> non sono riuscito a trovare una timezone chiamata <b>"+parts[1]+"</b>", &update.MessageID) broker.SendTextMessage(update.Chat, "<b>Errore:</b> non sono riuscito a trovare una timezone chiamata <b>"+parts[1]+"</b>", &tg.MessageOptions{
ReplyID: &update.MessageID,
})
return return
} }

View file

@ -48,7 +48,9 @@ func macro_message(broker *tg.Broker, update tg.APIMessage) {
} else { } else {
out = fmt.Sprintf("<b>%s</b>\n<i>macro inesistente</i>\n(configura con /macro %s <i>contenuto</i>)", macroname, macroname) out = fmt.Sprintf("<b>%s</b>\n<i>macro inesistente</i>\n(configura con /macro %s <i>contenuto</i>)", macroname, macroname)
} }
broker.SendTextMessage(update.Chat, out, &update.MessageID) broker.SendTextMessage(update.Chat, out, &tg.MessageOptions{
ReplyID: &update.MessageID,
})
case 3: case 3:
macroname := strings.ToLower(parts[1]) macroname := strings.ToLower(parts[1])
macros[macroname] = Macro{ macros[macroname] = Macro{
@ -57,9 +59,13 @@ func macro_message(broker *tg.Broker, update tg.APIMessage) {
Time: time.Now(), Time: time.Now(),
} }
savemacros() savemacros()
broker.SendTextMessage(update.Chat, fmt.Sprintf("<b>%s</b> → %s", macroname, parts[2]), &update.MessageID) broker.SendTextMessage(update.Chat, fmt.Sprintf("<b>%s</b> → %s", macroname, parts[2]), &tg.MessageOptions{
ReplyID: &update.MessageID,
})
default: default:
broker.SendTextMessage(update.Chat, "<b>Sintassi</b>\n<b>Leggi</b>: /macro <i>nome-macro</i>\n<b>Scrivi</b>: /macro <i>nome-macro</i> <i>contenuto macro</i>", &update.MessageID) broker.SendTextMessage(update.Chat, "<b>Sintassi</b>\n<b>Leggi</b>: /macro <i>nome-macro</i>\n<b>Scrivi</b>: /macro <i>nome-macro</i> <i>contenuto macro</i>", &tg.MessageOptions{
ReplyID: &update.MessageID,
})
} }
} }
} }

View file

@ -49,7 +49,9 @@ func meme_message(broker *tg.Broker, update tg.APIMessage) {
if strings.HasPrefix(caption, "/meme ") && len(caption) > 6 { if strings.HasPrefix(caption, "/meme ") && len(caption) > 6 {
idx := strings.Index(caption, ";") idx := strings.Index(caption, ";")
if idx < 0 { if idx < 0 {
broker.SendTextMessage(update.Chat, "<b>Formato</b>: /meme TESTO IN ALTO<b>;</b>TESTO IN BASSO", &update.MessageID) broker.SendTextMessage(update.Chat, "<b>Formato</b>: /meme TESTO IN ALTO<b>;</b>TESTO IN BASSO", &tg.MessageOptions{
ReplyID: &update.MessageID,
})
return return
} }
@ -68,21 +70,27 @@ func meme_message(broker *tg.Broker, update tg.APIMessage) {
broker.GetFile(photo.FileID, func(broker *tg.Broker, data tg.BrokerUpdate) { broker.GetFile(photo.FileID, func(broker *tg.Broker, data tg.BrokerUpdate) {
if data.Type == tg.BError { if data.Type == tg.BError {
log.Printf("[memegen] Received error from broker: %s\n", *data.Error) log.Printf("[memegen] Received error from broker: %s\n", *data.Error)
broker.SendTextMessage(update.Chat, "<b>ERRORE!</b> @hamcha controlla la console!", &update.MessageID) broker.SendTextMessage(update.Chat, "<b>ERRORE!</b> @hamcha controlla la console!", &tg.MessageOptions{
ReplyID: &update.MessageID,
})
return return
} }
pbytes, err := base64.StdEncoding.DecodeString(*data.Bytes) pbytes, err := base64.StdEncoding.DecodeString(*data.Bytes)
if err != nil { if err != nil {
log.Printf("[memegen] Base64 decode error: %s\n", err.Error()) log.Printf("[memegen] Base64 decode error: %s\n", err.Error())
broker.SendTextMessage(update.Chat, "<b>ERRORE!</b> @hamcha controlla la console!", &update.MessageID) broker.SendTextMessage(update.Chat, "<b>ERRORE!</b> @hamcha controlla la console!", &tg.MessageOptions{
ReplyID: &update.MessageID,
})
return return
} }
img, _, err := image.Decode(bytes.NewReader(pbytes)) img, _, err := image.Decode(bytes.NewReader(pbytes))
if err != nil { if err != nil {
log.Printf("[memegen] Image decode error: %s\n", err.Error()) log.Printf("[memegen] Image decode error: %s\n", err.Error())
broker.SendTextMessage(update.Chat, "<b>ERROR</b>: Non riesco a leggere l'immagine", &update.MessageID) broker.SendTextMessage(update.Chat, "<b>ERROR</b>: Non riesco a leggere l'immagine", &tg.MessageOptions{
ReplyID: &update.MessageID,
})
return return
} }
@ -176,10 +184,14 @@ func meme_message(broker *tg.Broker, update tg.APIMessage) {
err = jpeg.Encode(buf, timg, &(jpeg.Options{Quality: 80})) err = jpeg.Encode(buf, timg, &(jpeg.Options{Quality: 80}))
if err != nil { if err != nil {
log.Printf("[memegen] Image encode error: %s\n", err.Error()) log.Printf("[memegen] Image encode error: %s\n", err.Error())
broker.SendTextMessage(update.Chat, "<b>ERRORE!</b> @hamcha controlla la console!", &update.MessageID) broker.SendTextMessage(update.Chat, "<b>ERRORE!</b> @hamcha controlla la console!", &tg.MessageOptions{
ReplyID: &update.MessageID,
})
return return
} }
broker.SendPhoto(update.Chat, buf.Bytes(), "meme.jpg", "", &update.MessageID) broker.SendPhoto(update.Chat, buf.Bytes(), "meme.jpg", "", &tg.MessageOptions{
ReplyID: &update.MessageID,
})
}) })
} }
} }

View file

@ -66,6 +66,8 @@ func oroscopo_message(broker *tg.Broker, update tg.APIMessage) {
txt = txt[idx:] txt = txt[idx:]
break break
} }
broker.SendTextMessage(update.Chat, "<b>Ecco cosa dicono le stelle:</b>\n"+txt+".", &update.MessageID) broker.SendTextMessage(update.Chat, "<b>Ecco cosa dicono le stelle:</b>\n"+txt+".", &tg.MessageOptions{
ReplyID: &update.MessageID,
})
} }
} }

View file

@ -67,7 +67,9 @@ func remind_message(broker *tg.Broker, update tg.APIMessage) {
} }
if len(parts) < 3 { if len(parts) < 3 {
broker.SendTextMessage(update.Chat, "<b>Sintassi</b>\n/ricordami <i>[quando]</i> Messaggio\n\n<b>Formati supportati per [quando]</b>:\n 10s 10m 10h 10d (secondi/minuti/ore/giorni)\n 13:20 15:55:01 (ora dello stesso giorno, formato 24h)\n 11/02/2099 11/02/2099-11:20:01 (giorno diverso, stessa ora [1] o specifica [2])", &update.MessageID) broker.SendTextMessage(update.Chat, "<b>Sintassi</b>\n/ricordami <i>[quando]</i> Messaggio\n\n<b>Formati supportati per [quando]</b>:\n 10s 10m 10h 10d (secondi/minuti/ore/giorni)\n 13:20 15:55:01 (ora dello stesso giorno, formato 24h)\n 11/02/2099 11/02/2099-11:20:01 (giorno diverso, stessa ora [1] o specifica [2])", &tg.MessageOptions{
ReplyID: &update.MessageID,
})
return return
} }
@ -76,7 +78,9 @@ func remind_message(broker *tg.Broker, update tg.APIMessage) {
timestamp, err := parseDuration(format) timestamp, err := parseDuration(format)
if err != nil { if err != nil {
broker.SendTextMessage(update.Chat, err.Error(), &update.MessageID) broker.SendTextMessage(update.Chat, err.Error(), &tg.MessageOptions{
ReplyID: &update.MessageID,
})
return return
} }
@ -103,13 +107,17 @@ func remind_message(broker *tg.Broker, update tg.APIMessage) {
whenday = "il " + timestamp.Format("2/1") whenday = "il " + timestamp.Format("2/1")
} }
whentime := "alle " + timestamp.Format("15:04:05") whentime := "alle " + timestamp.Format("15:04:05")
broker.SendTextMessage(update.Chat, "Ok, vedrò di avvisarti "+whenday+" "+whentime, &update.MessageID) broker.SendTextMessage(update.Chat, "Ok, vedrò di avvisarti "+whenday+" "+whentime, &tg.MessageOptions{
ReplyID: &update.MessageID,
})
} }
if isCommand(update, "reminders") { if isCommand(update, "reminders") {
// Should only work in private chats // Should only work in private chats
if update.Chat.Type != tg.ChatTypePrivate { if update.Chat.Type != tg.ChatTypePrivate {
broker.SendTextMessage(update.Chat, "Per favore chiedimi in privato dei reminder", &update.MessageID) broker.SendTextMessage(update.Chat, "Per favore chiedimi in privato dei reminder", &tg.MessageOptions{
ReplyID: &update.MessageID,
})
return return
} }
@ -120,7 +128,16 @@ func remind_message(broker *tg.Broker, update tg.APIMessage) {
} }
} }
broker.SendTextMessage(update.Chat, fmt.Sprintf("Ci sono <b>%d</b> reminder in coda per te", len(useritems)), &update.MessageID) if len(useritems) == 0 {
broker.SendTextMessage(update.Chat, "Non ci sono reminder in coda per te", &tg.MessageOptions{
ReplyID: &update.MessageID,
})
} else {
broker.SendTextMessage(update.Chat, fmt.Sprintf("Ci sono <b>%d</b> reminder in coda per te", len(useritems)), &tg.MessageOptions{
ReplyID: &update.MessageID,
})
}
} }
} }

View file

@ -61,7 +61,9 @@ func search_message(broker *tg.Broker, update tg.APIMessage) {
if isCommand(update, "search") { if isCommand(update, "search") {
parts := strings.SplitN(*(update.Text), " ", 2) parts := strings.SplitN(*(update.Text), " ", 2)
if len(parts) < 2 { if len(parts) < 2 {
broker.SendTextMessage(update.Chat, "Non mi hai dato niente da cercare!", &update.MessageID) broker.SendTextMessage(update.Chat, "Non mi hai dato niente da cercare!", &tg.MessageOptions{
ReplyID: &update.MessageID,
})
return return
} }
broker.SendChatAction(update.Chat, tg.ActionTyping) broker.SendChatAction(update.Chat, tg.ActionTyping)
@ -69,12 +71,16 @@ func search_message(broker *tg.Broker, update tg.APIMessage) {
result, err := searchAPI(parts[1]) result, err := searchAPI(parts[1])
if err != nil { if err != nil {
log.Printf("[search] %s\n", err.Error()) log.Printf("[search] %s\n", err.Error())
broker.SendTextMessage(update.Chat, "<b>ERRORE!</b> @hamcha controlla la console!", &update.MessageID) broker.SendTextMessage(update.Chat, "<b>ERRORE!</b> @hamcha controlla la console!", &tg.MessageOptions{
ReplyID: &update.MessageID,
})
return return
} }
if result.None { if result.None {
broker.SendTextMessage(update.Chat, "Non ho trovato nulla, mi spiace :(", &update.MessageID) broker.SendTextMessage(update.Chat, "Non ho trovato nulla, mi spiace :(", &tg.MessageOptions{
ReplyID: &update.MessageID,
})
return return
} }
@ -86,7 +92,9 @@ func search_message(broker *tg.Broker, update tg.APIMessage) {
resulttxt += "\nAlternativamente:\n - " + strings.Join(result.Alternatives, "\n - ") resulttxt += "\nAlternativamente:\n - " + strings.Join(result.Alternatives, "\n - ")
} }
broker.SendTextMessage(update.Chat, resulttxt, &update.MessageID) broker.SendTextMessage(update.Chat, resulttxt, &tg.MessageOptions{
ReplyID: &update.MessageID,
})
} }
} }

View file

@ -68,21 +68,27 @@ func snapchat_message(broker *tg.Broker, update tg.APIMessage) {
broker.GetFile(photo.FileID, func(broker *tg.Broker, data tg.BrokerUpdate) { broker.GetFile(photo.FileID, func(broker *tg.Broker, data tg.BrokerUpdate) {
if data.Type == tg.BError { if data.Type == tg.BError {
log.Printf("[snapchat] Received error from broker: %s\n", *data.Error) log.Printf("[snapchat] Received error from broker: %s\n", *data.Error)
broker.SendTextMessage(update.Chat, "<b>ERRORE!</b> @hamcha controlla la console!", &update.MessageID) broker.SendTextMessage(update.Chat, "<b>ERRORE!</b> @hamcha controlla la console!", &tg.MessageOptions{
ReplyID: &update.MessageID,
})
return return
} }
pbytes, err := base64.StdEncoding.DecodeString(*data.Bytes) pbytes, err := base64.StdEncoding.DecodeString(*data.Bytes)
if err != nil { if err != nil {
log.Printf("[snapchat] Base64 decode error: %s\n", err.Error()) log.Printf("[snapchat] Base64 decode error: %s\n", err.Error())
broker.SendTextMessage(update.Chat, "<b>ERRORE!</b> @hamcha controlla la console!", &update.MessageID) broker.SendTextMessage(update.Chat, "<b>ERRORE!</b> @hamcha controlla la console!", &tg.MessageOptions{
ReplyID: &update.MessageID,
})
return return
} }
img, _, err := image.Decode(bytes.NewReader(pbytes)) img, _, err := image.Decode(bytes.NewReader(pbytes))
if err != nil { if err != nil {
log.Printf("[snapchat] Image decode error: %s\n", err.Error()) log.Printf("[snapchat] Image decode error: %s\n", err.Error())
broker.SendTextMessage(update.Chat, "<b>ERROR</b>: Non riesco a leggere l'immagine", &update.MessageID) broker.SendTextMessage(update.Chat, "<b>ERROR</b>: Non riesco a leggere l'immagine", &tg.MessageOptions{
ReplyID: &update.MessageID,
})
return return
} }
@ -159,10 +165,14 @@ func snapchat_message(broker *tg.Broker, update tg.APIMessage) {
err = jpeg.Encode(buf, timg, &(jpeg.Options{Quality: 80})) err = jpeg.Encode(buf, timg, &(jpeg.Options{Quality: 80}))
if err != nil { if err != nil {
log.Printf("[snapchat] Image encode error: %s\n", err.Error()) log.Printf("[snapchat] Image encode error: %s\n", err.Error())
broker.SendTextMessage(update.Chat, "<b>ERRORE!</b> @hamcha controlla la console!", &update.MessageID) broker.SendTextMessage(update.Chat, "<b>ERRORE!</b> @hamcha controlla la console!", &tg.MessageOptions{
ReplyID: &update.MessageID,
})
return return
} }
broker.SendPhoto(update.Chat, buf.Bytes(), "meme.jpg", "", &update.MessageID) broker.SendPhoto(update.Chat, buf.Bytes(), "meme.jpg", "", &tg.MessageOptions{
ReplyID: &update.MessageID,
})
}) })
} }
} }

View file

@ -34,26 +34,34 @@ func stt_message(broker *tg.Broker, update tg.APIMessage) {
// Make sure it's a voice message // Make sure it's a voice message
if update.Voice == nil { if update.Voice == nil {
broker.SendTextMessage(update.Chat, "Non vedo un messaggio vocale da ascoltare", &update.MessageID) broker.SendTextMessage(update.Chat, "Non vedo un messaggio vocale da ascoltare", &tg.MessageOptions{
ReplyID: &update.MessageID,
})
return return
} }
if update.Voice.Duration > 60 { if update.Voice.Duration > 60 {
broker.SendTextMessage(update.Chat, "L'audio dura un bel po' (> 1 minuto), al momento non posso farci nulla :S", &update.MessageID) broker.SendTextMessage(update.Chat, "L'audio dura un bel po' (> 1 minuto), al momento non posso farci nulla :S", &tg.MessageOptions{
ReplyID: &update.MessageID,
})
return return
} }
broker.GetFile(update.Voice.FileID, func(broker *tg.Broker, data tg.BrokerUpdate) { broker.GetFile(update.Voice.FileID, func(broker *tg.Broker, data tg.BrokerUpdate) {
if data.Type == tg.BError { if data.Type == tg.BError {
log.Printf("[stt] Received error from broker: %s\n", *data.Error) log.Printf("[stt] Received error from broker: %s\n", *data.Error)
broker.SendTextMessage(update.Chat, "<b>ERRORE!</b> @hamcha controlla la console!", &update.MessageID) broker.SendTextMessage(update.Chat, "<b>ERRORE!</b> @hamcha controlla la console!", &tg.MessageOptions{
ReplyID: &update.MessageID,
})
return return
} }
bytes, err := base64.StdEncoding.DecodeString(*data.Bytes) bytes, err := base64.StdEncoding.DecodeString(*data.Bytes)
if err != nil { if err != nil {
log.Printf("[stt] Base64 decode error: %s\n", err.Error()) log.Printf("[stt] Base64 decode error: %s\n", err.Error())
broker.SendTextMessage(update.Chat, "<b>ERRORE!</b> @hamcha controlla la console!", &update.MessageID) broker.SendTextMessage(update.Chat, "<b>ERRORE!</b> @hamcha controlla la console!", &tg.MessageOptions{
ReplyID: &update.MessageID,
})
return return
} }
@ -70,7 +78,9 @@ func stt_message(broker *tg.Broker, update tg.APIMessage) {
}) })
if err != nil { if err != nil {
log.Printf("[stt] STT request error: %s\n", err.Error()) log.Printf("[stt] STT request error: %s\n", err.Error())
broker.SendTextMessage(update.Chat, "<b>ERRORE!</b> @hamcha controlla la console!", &update.MessageID) broker.SendTextMessage(update.Chat, "<b>ERRORE!</b> @hamcha controlla la console!", &tg.MessageOptions{
ReplyID: &update.MessageID,
})
return return
} }
@ -81,7 +91,9 @@ func stt_message(broker *tg.Broker, update tg.APIMessage) {
} }
} }
broker.SendTextMessage(update.Chat, out, &update.MessageID) broker.SendTextMessage(update.Chat, out, &tg.MessageOptions{
ReplyID: &update.MessageID,
})
}) })
} }
} }

View file

@ -63,7 +63,9 @@ func unsplash_message(broker *tg.Broker, update tg.APIMessage) {
case update.ReplyTo.Caption != nil: case update.ReplyTo.Caption != nil:
text = *(update.ReplyTo.Caption) text = *(update.ReplyTo.Caption)
default: default:
broker.SendTextMessage(update.Chat, "Non c'e' niente di 'ispiratore' in questo..", &update.MessageID) broker.SendTextMessage(update.Chat, "Non c'e' niente di 'ispiratore' in questo..", &tg.MessageOptions{
ReplyID: &update.MessageID,
})
return return
} }
@ -89,14 +91,18 @@ func unsplash_message(broker *tg.Broker, update tg.APIMessage) {
author += " (" + user.Username + ")" author += " (" + user.Username + ")"
if strings.TrimSpace(text) == "" { if strings.TrimSpace(text) == "" {
broker.SendTextMessage(update.Chat, "Non c'e' niente di 'ispiratore' in questo..", &update.MessageID) broker.SendTextMessage(update.Chat, "Non c'e' niente di 'ispiratore' in questo..", &tg.MessageOptions{
ReplyID: &update.MessageID,
})
return return
} }
resp, err := http.Get(unsplashUrl) resp, err := http.Get(unsplashUrl)
if err != nil { if err != nil {
log.Printf("[unsplash] HTTP request failed: %s\nOriginal URL: %s\n", err.Error(), unsplashUrl) log.Printf("[unsplash] HTTP request failed: %s\nOriginal URL: %s\n", err.Error(), unsplashUrl)
broker.SendTextMessage(update.Chat, "<b>ERRORE!</b> @hamcha controlla la console!", &update.MessageID) broker.SendTextMessage(update.Chat, "<b>ERRORE!</b> @hamcha controlla la console!", &tg.MessageOptions{
ReplyID: &update.MessageID,
})
return return
} }
defer resp.Body.Close() defer resp.Body.Close()
@ -104,7 +110,9 @@ func unsplash_message(broker *tg.Broker, update tg.APIMessage) {
img, _, err := image.Decode(resp.Body) img, _, err := image.Decode(resp.Body)
if err != nil { if err != nil {
log.Printf("[unsplash] Image decode error: %s\nOriginal URL: %s\n", err.Error(), unsplashUrl) log.Printf("[unsplash] Image decode error: %s\nOriginal URL: %s\n", err.Error(), unsplashUrl)
broker.SendTextMessage(update.Chat, "<b>ERRORE</b>: Non riesco a leggere l'immagine", &update.MessageID) broker.SendTextMessage(update.Chat, "<b>ERRORE</b>: Non riesco a leggere l'immagine", &tg.MessageOptions{
ReplyID: &update.MessageID,
})
return return
} }
@ -199,9 +207,13 @@ func unsplash_message(broker *tg.Broker, update tg.APIMessage) {
err = jpeg.Encode(buf, timg, &(jpeg.Options{Quality: 80})) err = jpeg.Encode(buf, timg, &(jpeg.Options{Quality: 80}))
if err != nil { if err != nil {
log.Println("[unsplash] Image encode error: %s\n", err.Error()) log.Println("[unsplash] Image encode error: %s\n", err.Error())
broker.SendTextMessage(update.Chat, "<b>ERRORE!</b> @hamcha controlla la console!", &update.MessageID) broker.SendTextMessage(update.Chat, "<b>ERRORE!</b> @hamcha controlla la console!", &tg.MessageOptions{
ReplyID: &update.MessageID,
})
return return
} }
broker.SendPhoto(update.Chat, buf.Bytes(), "quote.jpg", "", &update.MessageID) broker.SendPhoto(update.Chat, buf.Bytes(), "quote.jpg", "", &tg.MessageOptions{
ReplyID: &update.MessageID,
})
} }
} }

View file

@ -43,16 +43,22 @@ func viaggi_message(broker *tg.Broker, update tg.APIMessage) {
out, err := viaggiAPI(msgs[1], msgs[2]) out, err := viaggiAPI(msgs[1], msgs[2])
if err != nil { if err != nil {
log.Println("[viaggi] " + err.Error()) log.Println("[viaggi] " + err.Error())
broker.SendTextMessage(update.Chat, "<b>ERRORE!</b> @hamcha controlla la console!", &update.MessageID) broker.SendTextMessage(update.Chat, "<b>ERRORE!</b> @hamcha controlla la console!", &tg.MessageOptions{
ReplyID: &update.MessageID,
})
return return
} }
broker.SendTextMessage(update.Chat, out, &update.MessageID) broker.SendTextMessage(update.Chat, out, &tg.MessageOptions{
ReplyID: &update.MessageID,
})
} }
} }
func viaggi_help(broker *tg.Broker, update tg.APIMessage) { func viaggi_help(broker *tg.Broker, update tg.APIMessage) {
broker.SendTextMessage(update.Chat, "Formato: /viaggi <i>&lt;PARTENZA&gt;</i> -> <i>&lt;DESTINAZIONE&gt;</i>", &update.MessageID) broker.SendTextMessage(update.Chat, "Formato: /viaggi <i>&lt;PARTENZA&gt;</i> -> <i>&lt;DESTINAZIONE&gt;</i>", &tg.MessageOptions{
ReplyID: &update.MessageID,
})
} }
func parseData(route Romeroute) string { func parseData(route Romeroute) string {