fix(Core/SpellAuras): prevent crash in Aura::GetType() (#6922)
This commit is contained in:
parent
8568c4fb33
commit
ee5ed33fec
1 changed files with 6 additions and 0 deletions
|
|
@ -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;
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue