Merge pull request #2289 from shaji-Dev/master

[ADDED] IsAlive condition for Unit and Group out message
This commit is contained in:
Thomas 2025-04-23 06:28:13 +02:00 committed by GitHub
commit 82c409d77a
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

View File

@ -206,7 +206,7 @@ end
function MESSAGE:ToGroup( Group, Settings )
self:F( Group.GroupName )
if Group then
if Group and Group:IsAlive() then
if self.MessageType then
local Settings = Settings or (Group and _DATABASE:GetPlayerSettings( Group:GetPlayerName() )) or _SETTINGS -- Core.Settings#SETTINGS
@ -231,7 +231,7 @@ end
function MESSAGE:ToUnit( Unit, Settings )
self:F( Unit.IdentifiableName )
if Unit then
if Unit and Unit:IsAlive() then
if self.MessageType then
local Settings = Settings or ( Unit and _DATABASE:GetPlayerSettings( Unit:GetPlayerName() ) ) or _SETTINGS -- Core.Settings#SETTINGS