mirror of
https://github.com/AyuGram/AyuGramDesktop.git
synced 2025-06-07 07:33:52 +02:00
fix: skill issue
Pro-tip: don't watch anime while coding.
This commit is contained in:
parent
7e62f8749d
commit
df0c1f814a
2 changed files with 4 additions and 2 deletions
|
@ -775,7 +775,8 @@ FilterId ChatFilters::defaultId() const {
|
||||||
}
|
}
|
||||||
|
|
||||||
FilterId ChatFilters::lookupId(int index) const {
|
FilterId ChatFilters::lookupId(int index) const {
|
||||||
if (index >= 0 && index < _list.size()) {
|
// Expects(index >= 0 && index < _list.size());
|
||||||
|
if (!(index >= 0 && index < _list.size())) {
|
||||||
return FilterId(); // AyuGram: fix crash when using `hideAllChatsFolder`
|
return FilterId(); // AyuGram: fix crash when using `hideAllChatsFolder`
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -62,7 +62,8 @@ SparseIdsList::AddResult SparseIdsList::addRangeItemsAndCountNew(
|
||||||
SparseIdsSliceUpdate &update,
|
SparseIdsSliceUpdate &update,
|
||||||
const Range &messages,
|
const Range &messages,
|
||||||
MsgRange noSkipRange) {
|
MsgRange noSkipRange) {
|
||||||
if (noSkipRange.from <= noSkipRange.till) {
|
// Expects(noSkipRange.from <= noSkipRange.till);
|
||||||
|
if (!(noSkipRange.from <= noSkipRange.till)) {
|
||||||
return { 0 }; // AyuGram: fix crash when using `saveDeletedMessages`
|
return { 0 }; // AyuGram: fix crash when using `saveDeletedMessages`
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Add table
Reference in a new issue