diff --git a/Aptechka.lua b/Aptechka.lua index c16a678..86bdc97 100644 --- a/Aptechka.lua +++ b/Aptechka.lua @@ -290,7 +290,7 @@ function Aptechka.PLAYER_LOGIN(self,event,arg1) Aptechka.Roster = Roster if AptechkaDB.global.disableBlizzardPlayer then - helpers.DisableBlizzPlayerFrame() + Aptechka:SafeCallDirect(helpers.DisableBlizzPlayerFrame) end if AptechkaDB.global.disableBlizzardParty then helpers.DisableBlizzParty() @@ -2291,6 +2291,18 @@ do end end end + local errorhandler2 = function(err) + print("|cffff7777Aptechka Error:|r") + print(err) + end + function Aptechka:SafeCallDirect(func, ...) + if func then + local ok, ret = xpcall(func, errorhandler2, ...) + if ok then + return ret + end + end + end end function Aptechka.SetupFrame(header, frameName)