Enforce suppressed buff persistence schema

This commit is contained in:
Vayle
2026-03-08 11:33:31 -04:00
parent db4f3d141d
commit 7da9bd74eb
3 changed files with 133 additions and 1 deletions
+10 -1
View File
@@ -2934,7 +2934,16 @@ void ZoneDatabase::SaveBuffs(Client *client)
}
if (!v.empty()) {
CharacterBuffsRepository::ReplaceMany(database, v);
const auto saved_count = CharacterBuffsRepository::ReplaceMany(database, v);
if (saved_count != static_cast<int>(v.size())) {
LogError(
"Failed to save all buffs for character [{}] [{}]. Expected [{}] rows, saved [{}]. Verify the `character_buffs` schema is up to date.",
client->GetCleanName(),
client->CharacterID(),
v.size(),
saved_count
);
}
}
}