Commit b93410ad authored by Ingo Klöcker's avatar Ingo Klöcker
Browse files

Inform the user if the issuer certificate wasn't found

GnuPG-bug-id: 5843
parent bc7c8c58
......@@ -1076,12 +1076,14 @@ void CertificateDetailsWidget::Private::setupSMIMEProperties()
void CertificateDetailsWidget::Private::showIssuerCertificate()
const auto parentKey = KeyCache::instance()->findIssuers(key, KeyCache::NoOption);
// there is either one or no parent key
const auto parentKeys = KeyCache::instance()->findIssuers(key, KeyCache::NoOption);
if (!parentKey.size()) {
if (parentKeys.empty()) {
KMessageBox::error(q, i18n("The issuer certificate could not be found locally."));
auto cmd = new Kleo::Commands::DetailsCommand(parentKey[0], nullptr);
auto cmd = new Kleo::Commands::DetailsCommand(parentKeys.front(), nullptr);
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment