Skip to content

Commit

Permalink
Fix: Cleanning tooltip string now correctly works if it contains the …
Browse files Browse the repository at this point in the history
…single quote character

- Minor improvement
  • Loading branch information
spamwax committed Aug 3, 2024
1 parent f32a261 commit 9370841
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions EavesDrop.lua
Original file line number Diff line number Diff line change
Expand Up @@ -259,7 +259,7 @@ end
local function cleanstring(s)
s = gsub(s, "|r", "")
s = gsub(s, "|c........", "")
s = gsub(s, "|Hunit:([%w%s*%-*:]*)|h", "")
s = gsub(s, "|Hunit:([%w%s*%-*:%']*)|h", "")
s = gsub(s, "|Haction:([%w_*]*)|h", "")
s = gsub(s, "|Hitem:(%d+)|h", "")
s = gsub(s, "|Hicon:%d+:dest|h", "")
Expand Down Expand Up @@ -1039,7 +1039,7 @@ function EavesDrop:CombatEvent(_, _)
texture = nil
if (playerRelated or petRelated) and not toPlayer then
local _color
if toPet and not toPlayer then _color = { r = 1, g = 0.27, b = 0.2, a = 1 } end
if toPet then _color = { r = 1, g = 0.27, b = 0.2, a = 1 } end
text = deathchar .. destName .. deathchar
self:DisplayEvent(MISC, text, texture, _color or db["DEATH"], message)
end
Expand Down

0 comments on commit 9370841

Please sign in to comment.