aboutsummaryrefslogtreecommitdiffstats
path: root/src/core/model/GpgKeyTableProxyModel.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/core/model/GpgKeyTableProxyModel.cpp')
-rw-r--r--src/core/model/GpgKeyTableProxyModel.cpp11
1 files changed, 8 insertions, 3 deletions
diff --git a/src/core/model/GpgKeyTableProxyModel.cpp b/src/core/model/GpgKeyTableProxyModel.cpp
index 5ed9ade3..aa5cc4b1 100644
--- a/src/core/model/GpgKeyTableProxyModel.cpp
+++ b/src/core/model/GpgKeyTableProxyModel.cpp
@@ -83,12 +83,17 @@ auto GpgKeyTableProxyModel::filterAcceptsRow(
for (int column = 0; column < sourceModel()->columnCount(); ++column) {
auto index = sourceModel()->index(source_row, column, sourceParent);
infos << sourceModel()->data(index).toString();
- }
- for (const QString &info : infos) {
- if (info.contains(filter_keywords_, Qt::CaseInsensitive)) return true;
+ const auto uids = key.GetUIDs();
+ for (const auto &uid : *uids) {
+ infos << uid.GetUID();
+ }
}
+ return std::any_of(infos.cbegin(), infos.cend(), [&](const QString &info) {
+ return info.contains(filter_keywords_, Qt::CaseInsensitive);
+ });
+
return false;
}