diff --git a/applets/kicker/plugin/actionlist.cpp b/applets/kicker/plugin/actionlist.cpp index c161eda15..c595a1480 100644 --- a/applets/kicker/plugin/actionlist.cpp +++ b/applets/kicker/plugin/actionlist.cpp @@ -345,6 +345,9 @@ bool handleRecentDocumentAction(KService::Ptr service, const QString &actionId, } const QStringList argument = _argument.toStringList(); + if (argument.isEmpty()) { + return false; + } const auto resource = argument.at(0); const auto mimeType = argument.at(1); @@ -362,10 +365,6 @@ bool handleRecentDocumentAction(KService::Ptr service, const QString &actionId, } } - if (argument.isEmpty()) { - return false; - } - auto *job = new KIO::ApplicationLauncherJob(service); job->setUrls({QUrl::fromUserInput(resource)}); job->setUiDelegate(new KNotificationJobUiDelegate(KJobUiDelegate::AutoHandlingEnabled));