From f604b865cc119717e3dbe4296f20f9b3db0a1c87 Mon Sep 17 00:00:00 2001 From: saturneric Date: Fri, 26 Jan 2024 01:24:23 +0800 Subject: feat: enhance keys searching functions --- src/core/GpgCoreInit.cpp | 12 +++++++++++- 1 file changed, 11 insertions(+), 1 deletion(-) (limited to 'src/core/GpgCoreInit.cpp') diff --git a/src/core/GpgCoreInit.cpp b/src/core/GpgCoreInit.cpp index 04531faf..38b8f33a 100644 --- a/src/core/GpgCoreInit.cpp +++ b/src/core/GpgCoreInit.cpp @@ -438,7 +438,17 @@ void InitGpgFrontendCore(CoreInitArgs args) { "received callback from gnupg-info-gathering "); // try to restart all components - GpgFrontend::GpgAdvancedOperator::RestartGpgComponents(); + auto settings = + GlobalSettingStation::GetInstance().GetSettings(); + auto restart_all_gnupg_components_on_start = + settings + .value("gnupg/restart_all_gnupg_components_on_start", + false) + .toBool(); + + if (restart_all_gnupg_components_on_start) { + GpgAdvancedOperator::RestartGpgComponents(); + } Module::UpsertRTValue("core", "env.state.gnupg", 1); // announce that all checkings were finished -- cgit v1.2.3