diff --git a/Telegram/SourceFiles/inline_bots/inline_bot_result.cpp b/Telegram/SourceFiles/inline_bots/inline_bot_result.cpp index da1b8fbd3..94a1d2da3 100644 --- a/Telegram/SourceFiles/inline_bots/inline_bot_result.cpp +++ b/Telegram/SourceFiles/inline_bots/inline_bot_result.cpp @@ -107,7 +107,8 @@ std::unique_ptr Result::create(uint64 queryId, const MTPBotInlineResult message = &r.vsend_message; } break; } - bool badAttachment = (result->_photo && !result->_photo->access) || (result->_document && !result->_document->isValid()); + auto badAttachment = (result->_photo && result->_photo->full->isNull()) + || (result->_document && !result->_document->isValid()); if (!message) { return nullptr; diff --git a/Telegram/SourceFiles/ui/images.cpp b/Telegram/SourceFiles/ui/images.cpp index f0e65bd3b..e5a31af8d 100644 --- a/Telegram/SourceFiles/ui/images.cpp +++ b/Telegram/SourceFiles/ui/images.cpp @@ -1324,10 +1324,10 @@ Image *getImage(const MTPDwebDocumentNoProxy &document) { } Image *getImage(const MTPDwebDocument &document, QSize box) { - const auto size = getImageSize(document.vattributes.v); - if (size.isEmpty()) { - return blank(); - } + //const auto size = getImageSize(document.vattributes.v); + //if (size.isEmpty()) { + // return blank(); + //} // We don't use size from WebDocument, because it is not reliable. // It can be > 0 and different from the real size that we get in upload.WebFile result. @@ -1342,10 +1342,10 @@ Image *getImage(const MTPDwebDocument &document, QSize box) { } Image *getImage(const MTPDwebDocumentNoProxy &document, QSize box) { - const auto size = getImageSize(document.vattributes.v); - if (size.isEmpty()) { - return blank(); - } + //const auto size = getImageSize(document.vattributes.v); + //if (size.isEmpty()) { + // return blank(); + //} return getImage(qs(document.vurl), box); }