mirror of
https://github.com/keepassxreboot/keepassxc.git
synced 2024-10-01 01:26:01 -04: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