From 19c3219f96e33306f92a5d9eeca38b3316a20da5 Mon Sep 17 00:00:00 2001 From: fed <58637860+fedddddd@users.noreply.github.com> Date: Sun, 11 Sep 2022 20:13:56 +0200 Subject: [PATCH] Small fix --- src/client/component/fastfiles.cpp | 16 +++++++++------- src/client/component/updater.cpp | 2 +- 2 files changed, 10 insertions(+), 8 deletions(-) diff --git a/src/client/component/fastfiles.cpp b/src/client/component/fastfiles.cpp index 5b3351a0..b4b4de43 100644 --- a/src/client/component/fastfiles.cpp +++ b/src/client/component/fastfiles.cpp @@ -228,16 +228,18 @@ namespace fastfiles return INVALID_HANDLE_VALUE; } - if (name.ends_with(".ff")) + auto handle = sys_createfile_hook.invoke(folder, base_filename); + if (handle != INVALID_HANDLE_VALUE) { - const auto handle = find_fastfile(name, true); - if (handle != INVALID_HANDLE_VALUE) - { - return handle; - } + return handle; } - return sys_createfile_hook.invoke(folder, base_filename); + if (name.ends_with(".ff")) + { + handle = find_fastfile(name, true); + } + + return handle; } template diff --git a/src/client/component/updater.cpp b/src/client/component/updater.cpp index d19cdc8a..95630eef 100644 --- a/src/client/component/updater.cpp +++ b/src/client/component/updater.cpp @@ -328,7 +328,7 @@ namespace updater { return update_data.access([](update_data_t& data_) { - return data_.check.done; + return data_.check.done && game::Sys_IsDatabaseReady2(); }); }