GetLocate on the fly instead of relying on a cached value

This commit is contained in:
Tercio Jose
2020-06-03 19:55:42 -03:00
parent fedfe341a3
commit c2007529d6
+3 -2
View File
@@ -24,6 +24,7 @@
local AddUnique = DetailsFramework.table.addunique --framework
local UnitGroupRolesAssigned = DetailsFramework.UnitGroupRolesAssigned --framework
local GetLocale = _G.GetLocale
-----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
--> constants
@@ -432,7 +433,7 @@
--if the user client is in russian language
--make an attempt to remove declensions from the character's name
--this is equivalent to remove 's from the owner on enUS
if (CONST_CLIENT_LANGUAGE == "ruRU") then
if (GetLocale() == "ruRU") then
if (find_name_declension (text1, playerName)) then
return find_pet_found_owner (pName, serial, nome, flag, self)
else
@@ -455,7 +456,7 @@
local pName = playerName
playerName = playerName:gsub ("%-.*", "") --remove realm name
if (CONST_CLIENT_LANGUAGE == "ruRU") then
if (GetLocale() == "ruRU") then
if (find_name_declension (text2, playerName)) then
return find_pet_found_owner (pName, serial, nome, flag, self)
else