mirror of
https://github.com/keepassxreboot/keepassxc.git
synced 2024-12-25 23:39:45 -05:00
FdoSecrets: fix all exposed entries are returned if search with empty terms
This commit is contained in:
parent
8459a216a5
commit
3ffeab4c41
@ -242,6 +242,11 @@ namespace FdoSecrets
|
|||||||
terms << attributeToTerm(it.key(), it.value());
|
terms << attributeToTerm(it.key(), it.value());
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// empty terms causes EntrySearcher returns everything
|
||||||
|
if (terms.isEmpty()) {
|
||||||
|
return QList<Item*>{};
|
||||||
|
}
|
||||||
|
|
||||||
QList<Item*> items;
|
QList<Item*> items;
|
||||||
const auto foundEntries = EntrySearcher().search(terms, m_exposedGroup);
|
const auto foundEntries = EntrySearcher().search(terms, m_exposedGroup);
|
||||||
items.reserve(foundEntries.size());
|
items.reserve(foundEntries.size());
|
||||||
|
Loading…
Reference in New Issue
Block a user