diff --git a/Telegram/SourceFiles/history/view/media/history_view_web_page.cpp b/Telegram/SourceFiles/history/view/media/history_view_web_page.cpp index 38b6dc258..844963a5e 100644 --- a/Telegram/SourceFiles/history/view/media/history_view_web_page.cpp +++ b/Telegram/SourceFiles/history/view/media/history_view_web_page.cpp @@ -155,7 +155,7 @@ bool WebPage::HasButton(not_null webpage) { } QSize WebPage::countOptimalSize() { - if (_data->pendingTill) { + if (_data->pendingTill || _data->failed) { return { 0, 0 }; } @@ -366,7 +366,7 @@ QSize WebPage::countOptimalSize() { } QSize WebPage::countCurrentSize(int newWidth) { - if (_data->pendingTill) { + if (_data->pendingTill || _data->failed) { return { newWidth, minHeight() }; } @@ -891,6 +891,7 @@ void WebPage::playAnimation(bool autoplay) { bool WebPage::isDisplayed() const { const auto item = _parent->data(); return !_data->pendingTill + && !_data->failed && !item->Has(); }