From 131f6eba38734212e039845b6cd9deabbc9d978d Mon Sep 17 00:00:00 2001 From: Bohdan Horbeshko Date: Mon, 31 Jul 2023 22:00:58 -0400 Subject: [PATCH] Use previews only instead of TGS stickers --- telegabber.go | 2 +- telegram/utils.go | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/telegabber.go b/telegabber.go index 5bb69d6..cfeecda 100644 --- a/telegabber.go +++ b/telegabber.go @@ -15,7 +15,7 @@ import ( goxmpp "gosrc.io/xmpp" ) -var version string = "1.7.0" +var version string = "1.7.1" var commit string var sm *goxmpp.StreamManager diff --git a/telegram/utils.go b/telegram/utils.go index e1e9317..cd25c22 100644 --- a/telegram/utils.go +++ b/telegram/utils.go @@ -770,7 +770,7 @@ func (c *Client) contentToFile(content client.MessageContent) (*client.File, *cl case client.TypeMessageSticker: sticker, _ := content.(*client.MessageSticker) file := sticker.Sticker.Sticker - if sticker.Sticker.Format.StickerFormatType() != client.TypeStickerTypeRegular && sticker.Sticker.Thumbnail != nil && sticker.Sticker.Thumbnail.File != nil { + if sticker.Sticker.Format.StickerFormatType() == client.TypeStickerFormatTgs && sticker.Sticker.Thumbnail != nil && sticker.Sticker.Thumbnail.File != nil { file = sticker.Sticker.Thumbnail.File } return file, nil