mirror of
https://github.com/AyuGram/AyuGramDesktop.git
synced 2025-04-16 14:17:12 +02:00
Fix a possible crash in messages list.
This commit is contained in:
parent
2d31704bde
commit
e71f614f4d
1 changed files with 1 additions and 1 deletions
|
@ -933,7 +933,7 @@ Element *ListWidget::viewByPosition(Data::MessagePosition position) const {
|
|||
const auto result = (index < 0) ? nullptr : _items[index].get();
|
||||
return (position == Data::MinMessagePosition
|
||||
|| position == Data::MaxMessagePosition
|
||||
|| result->data()->position() == position)
|
||||
|| (result && result->data()->position() == position))
|
||||
? result
|
||||
: nullptr;
|
||||
}
|
||||
|
|
Loading…
Add table
Reference in a new issue