mirror of
https://github.com/kotatogram/kotatogram-desktop
synced 2025-09-05 09:05:14 +00:00
Simplified ranges::find_if with ranges::any_of and ranges::none_of.
This commit is contained in:
@@ -101,8 +101,7 @@ auto SuggestionsWidget::getRowsByQuery() const -> std::vector<Row> {
|
||||
return false;
|
||||
}
|
||||
// Suggest :D and :-P only as exact matches.
|
||||
return ranges::find_if(_query, [](QChar ch) { return ch.isLower(); })
|
||||
== _query.end();
|
||||
return ranges::none_of(_query, [](QChar ch) { return ch.isLower(); });
|
||||
}();
|
||||
const auto exact = !middle || simple;
|
||||
const auto list = Core::App().emojiKeywords().query(real, exact);
|
||||
|
Reference in New Issue
Block a user