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

Fix crash in edited and replied message destruction.

This commit is contained in:
John Preston
2020-06-30 20:01:17 +04:00
parent 41f2cc6d81
commit 20ea3af2f0

View File

@@ -4943,12 +4943,11 @@ void HistoryWidget::updateControlsGeometry() {
}
void HistoryWidget::itemRemoved(not_null<const HistoryItem*> item) {
if (item == _replyEditMsg) {
if (_editMsgId) {
cancelEdit();
} else {
cancelReply();
}
if (item == _replyEditMsg && _editMsgId) {
cancelEdit();
}
if (item == _replyEditMsg && _replyToId) {
cancelReply();
}
while (item == _replyReturn) {
calcNextReplyReturn();