mirror of
https://github.com/EQEmu/Server.git
synced 2026-09-02 04:16:46 +00:00
[Logging] Remove function prefixes (#2766)
This commit is contained in:
+5
-5
@@ -391,7 +391,7 @@ bool Database::DeleteCharacter(char *character_name)
|
||||
}
|
||||
|
||||
if (character_id <= 0) {
|
||||
LogError("[DeleteCharacter] Invalid Character ID [{}]", character_name);
|
||||
LogError("Invalid Character ID [{}]", character_name);
|
||||
return false;
|
||||
}
|
||||
|
||||
@@ -431,7 +431,7 @@ bool Database::DeleteCharacter(char *character_name)
|
||||
character_id
|
||||
);
|
||||
QueryDatabase(query);
|
||||
LogInfo("[DeleteCharacter] character_name [{}] ({}) bots are being [{}]", character_name, character_id, delete_type);
|
||||
LogInfo("character_name [{}] ({}) bots are being [{}]", character_name, character_id, delete_type);
|
||||
#endif
|
||||
|
||||
return true;
|
||||
@@ -444,7 +444,7 @@ bool Database::DeleteCharacter(char *character_name)
|
||||
QueryDatabase(fmt::format("DELETE FROM {} WHERE {} = {}", table_name, character_id_column_name, character_id));
|
||||
}
|
||||
|
||||
LogInfo("[DeleteCharacter] character_name [{}] ({}) is being [{}]", character_name, character_id, delete_type);
|
||||
LogInfo("character_name [{}] ({}) is being [{}]", character_name, character_id, delete_type);
|
||||
|
||||
return true;
|
||||
}
|
||||
@@ -2356,7 +2356,7 @@ void Database::SourceDatabaseTableFromUrl(std::string table_name, std::string ur
|
||||
uri request_uri(url);
|
||||
|
||||
LogHTTP(
|
||||
"[SourceDatabaseTableFromUrl] parsing url [{}] path [{}] host [{}] query_string [{}] protocol [{}] port [{}]",
|
||||
"parsing url [{}] path [{}] host [{}] query_string [{}] protocol [{}] port [{}]",
|
||||
url,
|
||||
request_uri.get_path(),
|
||||
request_uri.get_host(),
|
||||
@@ -2410,7 +2410,7 @@ void Database::SourceDatabaseTableFromUrl(std::string table_name, std::string ur
|
||||
|
||||
}
|
||||
catch (std::invalid_argument iae) {
|
||||
LogError("[SourceDatabaseTableFromUrl] URI parser error [{}]", iae.what());
|
||||
LogError("URI parser error [{}]", iae.what());
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@@ -48,7 +48,7 @@ void Discord::SendWebhookMessage(const std::string &message, const std::string &
|
||||
while (retry) {
|
||||
if (auto res = cli.Post(endpoint.c_str(), payload.str(), "application/json")) {
|
||||
if (res->status != 200 && res->status != 204) {
|
||||
LogError("[Discord Client] Code [{}] Error [{}]", res->status, res->body);
|
||||
LogError("Code [{}] Error [{}]", res->status, res->body);
|
||||
}
|
||||
if (res->status == 429) {
|
||||
if (!res->body.empty()) {
|
||||
|
||||
+1
-1
@@ -198,7 +198,7 @@ std::string IpUtil::DNSLookupSync(const std::string &addr, int port)
|
||||
std::chrono::steady_clock::time_point end = std::chrono::steady_clock::now();
|
||||
if (std::chrono::duration_cast<std::chrono::milliseconds>(end - begin).count() > 1500) {
|
||||
LogInfo(
|
||||
"[DNSLookupSync] Deadline exceeded [{}]",
|
||||
"Deadline exceeded [{}]",
|
||||
1500
|
||||
);
|
||||
running = false;
|
||||
|
||||
@@ -109,7 +109,7 @@ bool ServerEventScheduler::ValidateEventReadyToActivate(
|
||||
|
||||
if (now_time_unix >= start_time_unix && (doesnt_end || now_time_unix < end_time_unix)) {
|
||||
LogSchedulerDetail(
|
||||
"[ValidateEventReadyToActivate] now_time [{}] start_time [{}] doesnt_end [{}] end_time [{}]",
|
||||
"now_time [{}] start_time [{}] doesnt_end [{}] end_time [{}]",
|
||||
now_time_unix,
|
||||
start_time_unix,
|
||||
doesnt_end ? "true" : "false",
|
||||
@@ -131,7 +131,7 @@ ServerEventScheduler *ServerEventScheduler::SetDatabase(Database *db)
|
||||
bool ServerEventScheduler::ValidateDatabaseConnection()
|
||||
{
|
||||
if (!m_database) {
|
||||
LogError("[ServerEventScheduler::LoadScheduledEvents] No database connection");
|
||||
LogError("No database connection");
|
||||
return false;
|
||||
}
|
||||
|
||||
@@ -174,7 +174,7 @@ bool ServerEventScheduler::CheckIfEventsChanged()
|
||||
dbe.created_at != e.created_at ||
|
||||
dbe.deleted_at != e.deleted_at
|
||||
) {
|
||||
LogSchedulerDetail("[CheckIfEventsChanged] Field change detected");
|
||||
LogSchedulerDetail("Field change detected");
|
||||
m_events = events;
|
||||
return true;
|
||||
}
|
||||
|
||||
+4
-4
@@ -1919,7 +1919,7 @@ void SharedDatabase::LoadSpells(void *data, int max_spells) {
|
||||
}
|
||||
|
||||
if(results.ColumnCount() <= SPELL_LOAD_FIELD_COUNT) {
|
||||
LogSpells("[SharedDatabase::LoadSpells] Fatal error loading spells: Spell field count < SPELL_LOAD_FIELD_COUNT([{}])", SPELL_LOAD_FIELD_COUNT);
|
||||
LogSpells("Fatal error loading spells: Spell field count < SPELL_LOAD_FIELD_COUNT([{}])", SPELL_LOAD_FIELD_COUNT);
|
||||
return;
|
||||
}
|
||||
|
||||
@@ -1928,9 +1928,9 @@ void SharedDatabase::LoadSpells(void *data, int max_spells) {
|
||||
for (auto& row = results.begin(); row != results.end(); ++row) {
|
||||
const int tempid = atoi(row[0]);
|
||||
if(tempid >= max_spells) {
|
||||
LogSpells("[SharedDatabase::LoadSpells] Non fatal error: spell.id >= max_spells, ignoring");
|
||||
continue;
|
||||
}
|
||||
LogSpells("Non fatal error: spell.id >= max_spells, ignoring");
|
||||
continue;
|
||||
}
|
||||
|
||||
++counter;
|
||||
sp[tempid].id = tempid;
|
||||
|
||||
@@ -60,7 +60,7 @@ uint32 ZoneStore::GetZoneID(std::string zone_name)
|
||||
}
|
||||
}
|
||||
|
||||
LogInfo("[GetZoneID] Failed to get zone_name [{}]", zone_name);
|
||||
LogInfo("Failed to get zone_name [{}]", zone_name);
|
||||
|
||||
return 0;
|
||||
}
|
||||
@@ -117,7 +117,7 @@ std::string ZoneStore::GetZoneName(uint32 zone_id)
|
||||
}
|
||||
}
|
||||
|
||||
LogInfo("[GetZoneName] Failed to get zone long name by zone_id [{}]", zone_id);
|
||||
LogInfo("Failed to get zone long name by zone_id [{}]", zone_id);
|
||||
|
||||
return {};
|
||||
}
|
||||
@@ -134,7 +134,7 @@ std::string ZoneStore::GetZoneLongName(uint32 zone_id)
|
||||
}
|
||||
}
|
||||
|
||||
LogInfo("[GetZoneLongName] Failed to get zone long name by zone_id [{}]", zone_id);
|
||||
LogInfo("Failed to get zone long name by zone_id [{}]", zone_id);
|
||||
|
||||
return {};
|
||||
}
|
||||
@@ -152,7 +152,7 @@ ZoneRepository::Zone *ZoneStore::GetZone(uint32 zone_id, int version)
|
||||
}
|
||||
}
|
||||
|
||||
LogInfo("[GetZone] Failed to get zone by zone_id [{}] version [{}]", zone_id, version);
|
||||
LogInfo("Failed to get zone by zone_id [{}] version [{}]", zone_id, version);
|
||||
|
||||
return nullptr;
|
||||
}
|
||||
@@ -169,7 +169,7 @@ ZoneRepository::Zone *ZoneStore::GetZone(const char *in_zone_name)
|
||||
}
|
||||
}
|
||||
|
||||
LogInfo("[GetZone] Failed to get zone by zone_name [{}]", in_zone_name);
|
||||
LogInfo("Failed to get zone by zone_name [{}]", in_zone_name);
|
||||
|
||||
return nullptr;
|
||||
}
|
||||
@@ -206,7 +206,7 @@ ZoneRepository::Zone *ZoneStore::GetZoneWithFallback(uint32 zone_id, int version
|
||||
}
|
||||
}
|
||||
|
||||
LogInfo("[GetZoneWithFallback] Failed to get zone by zone_id [{}] version [{}]", zone_id, version);
|
||||
LogInfo("Failed to get zone by zone_id [{}] version [{}]", zone_id, version);
|
||||
|
||||
return nullptr;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user