refactor(Core/Misc): abs() to std::abs() (#9789)

This commit is contained in:
Kitzunu
2021-12-31 23:29:39 +01:00
committed by GitHub
parent fe9305c724
commit ac99eb48e1
25 changed files with 60 additions and 60 deletions

View File

@@ -4653,7 +4653,7 @@ void ObjectMgr::LoadQuests()
{
if (qinfo->RewardFactionId[j])
{
if (abs(qinfo->RewardFactionValueId[j]) > 9)
if (std::abs(qinfo->RewardFactionValueId[j]) > 9)
{
LOG_ERROR("sql.sql", "Quest %u has RewardFactionValueId%d = %i. That is outside the range of valid values (-9 to 9).", qinfo->GetQuestId(), j + 1, qinfo->RewardFactionValueId[j]);
}
@@ -4763,7 +4763,7 @@ void ObjectMgr::LoadQuests()
// fill additional data stores
if (qinfo->PrevQuestId)
{
if (_questTemplates.find(abs(qinfo->GetPrevQuestId())) == _questTemplates.end())
if (_questTemplates.find(std::abs(qinfo->GetPrevQuestId())) == _questTemplates.end())
{
LOG_ERROR("sql.sql", "Quest %d has PrevQuestId %i, but no such quest", qinfo->GetQuestId(), qinfo->GetPrevQuestId());
}