2
0
mirror of https://github.com/kotatogram/kotatogram-desktop synced 2025-08-31 06:35:14 +00:00

Show only box(512,512) .webp as stickers.

This commit is contained in:
John Preston
2020-07-15 11:49:54 +04:00
parent 9cf15da2b1
commit 8aafe6ba0e
5 changed files with 18 additions and 18 deletions

View File

@@ -842,10 +842,7 @@ void FileLoadTask::process() {
if (ValidateThumbDimensions(w, h)) {
isSticker = Core::IsMimeSticker(filemime)
&& (w > 0)
&& (h > 0)
&& (w <= StickerMaxSize)
&& (h <= StickerMaxSize)
&& GoodStickerDimensions(w, h)
&& (filesize < Storage::kMaxStickerBytesSize);
if (isSticker) {
attributes.push_back(MTP_documentAttributeSticker(