mirror of
https://github.com/mod-playerbots/azerothcore-wotlk.git
synced 2026-01-16 10:30:27 +00:00
fix(Core/SpellAuras): prevent crash in Aura::GetType() (#6922)
This commit is contained in:
@@ -464,6 +464,12 @@ Unit* Aura::GetCaster() const
|
||||
|
||||
AuraObjectType Aura::GetType() const
|
||||
{
|
||||
if (!m_owner)
|
||||
{
|
||||
LOG_ERROR("spells", "Aura::GetType m_owner is null!");
|
||||
return UNIT_AURA_TYPE;
|
||||
}
|
||||
|
||||
return (m_owner->GetTypeId() == TYPEID_DYNAMICOBJECT) ? DYNOBJ_AURA_TYPE : UNIT_AURA_TYPE;
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user