diff --git a/src/Cache.cpp b/src/Cache.cpp index 6b3067db..de377f49 100644 --- a/src/Cache.cpp +++ b/src/Cache.cpp @@ -661,6 +661,10 @@ Cache::secret(const std::string &name) "Restoring secret '{}' failed: {}", name, job.errorString().toStdString()); return std::nullopt; } + if (secret.isEmpty()) { + nhlog::db()->debug("Restored empty secret '{}'.", name); + return std::nullopt; + } return secret.toStdString(); }