mirror of
https://github.com/EQEmu/Server.git
synced 2026-04-03 17:32:33 +00:00
Revert "Added auto-correcting code to logsys category descriptions (thanks kentaiVZ!)"
This reverts commit 7de655ba769f2e5c1b27d1ab609d2fbdb8f25ac2.
This commit is contained in:
parent
c646942ed1
commit
8f3689e023
@ -2134,7 +2134,6 @@ void Database::LoadLogSettings(EQEmuLogSys::LogSettings *log_settings)
|
|||||||
int log_category_id = 0;
|
int log_category_id = 0;
|
||||||
|
|
||||||
int *categories_in_database = new int[1000];
|
int *categories_in_database = new int[1000];
|
||||||
int* category_description_validation = new int[1000];
|
|
||||||
|
|
||||||
for (auto row = results.begin(); row != results.end(); ++row) {
|
for (auto row = results.begin(); row != results.end(); ++row) {
|
||||||
log_category_id = atoi(row[0]);
|
log_category_id = atoi(row[0]);
|
||||||
@ -2168,10 +2167,6 @@ void Database::LoadLogSettings(EQEmuLogSys::LogSettings *log_settings)
|
|||||||
}
|
}
|
||||||
|
|
||||||
categories_in_database[log_category_id] = 1;
|
categories_in_database[log_category_id] = 1;
|
||||||
|
|
||||||
if (strcmp(row[1], Logs::LogCategoryName[log_category_id]) == 0) {
|
|
||||||
category_description_validation[log_category_id] = 1;
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
@ -2203,27 +2198,9 @@ void Database::LoadLogSettings(EQEmuLogSys::LogSettings *log_settings)
|
|||||||
|
|
||||||
QueryDatabase(inject_query);
|
QueryDatabase(inject_query);
|
||||||
}
|
}
|
||||||
else if (category_description_validation[log_index] != 1) {
|
|
||||||
|
|
||||||
LogInfo(
|
|
||||||
"Updating Log Category Description [{0}]...",
|
|
||||||
Logs::LogCategoryName[log_index]
|
|
||||||
);
|
|
||||||
|
|
||||||
auto update_query = fmt::format(
|
|
||||||
"UPDATE logsys_categories "
|
|
||||||
"SET log_category_description = '{0}' "
|
|
||||||
"WHERE log_category_id = {1}",
|
|
||||||
EscapeString(Logs::LogCategoryName[log_index]),
|
|
||||||
log_index
|
|
||||||
);
|
|
||||||
|
|
||||||
QueryDatabase(update_query);
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|
||||||
delete[] categories_in_database;
|
delete[] categories_in_database;
|
||||||
delete[] category_description_validation;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
int Database::CountInvSnapshots() {
|
int Database::CountInvSnapshots() {
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user