Codechange: make Subdirectory a scoped enum

This commit is contained in:
Peter Nelson
2026-04-05 19:02:51 +01:00
committed by Peter Nelson
parent 93a6aa77c6
commit 5aae8e2d64
52 changed files with 218 additions and 216 deletions
+2 -2
View File
@@ -111,14 +111,14 @@ void DumpDebugFacilityNames(std::back_insert_iterator<std::string> &output_itera
void DebugPrint(std::string_view category, int level, std::string &&message)
{
if (category == "desync" && level != 0) {
static auto f = FioFOpenFile("commands-out.log", "wb", AUTOSAVE_DIR);
static auto f = FioFOpenFile("commands-out.log", "wb", Subdirectory::Autosave);
if (!f.has_value()) return;
fmt::print(*f, "{}{}\n", GetLogPrefix(true), message);
fflush(*f);
#ifdef RANDOM_DEBUG
} else if (category == "random") {
static auto f = FioFOpenFile("random-out.log", "wb", AUTOSAVE_DIR);
static auto f = FioFOpenFile("random-out.log", "wb", Subdirectory::Autosave);
if (!f.has_value()) return;
fmt::print(*f, "{}\n", message);