feat: add update flag

This commit is contained in:
Diavolo 2023-04-12 11:06:45 +02:00
parent 0205bea826
commit 231c19be93

View File

@ -5,6 +5,7 @@
#include "file_updater.hpp"
#include <utils/cryptography.hpp>
#include <utils/flags.hpp>
#include <utils/http.hpp>
#include <utils/io.hpp>
#include <utils/compression.hpp>
@ -271,7 +272,7 @@ namespace updater
bool file_updater::is_outdated_file(const file_info& file) const
{
#if !defined(NDEBUG) || !defined(CI)
if (file.name == UPDATE_HOST_BINARY)
if (file.name == UPDATE_HOST_BINARY && !utils::flags::has_flag("update"))
{
return false;
}