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

Fix inline bots with photos.

This commit is contained in:
John Preston
2018-03-13 13:29:42 +03:00
parent f792b0052f
commit 7de15ce5cf
2 changed files with 10 additions and 9 deletions

View File

@@ -107,7 +107,8 @@ std::unique_ptr<Result> 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;