mirror of
https://github.com/brues-code/pfUI.git
synced 2026-11-02 00:46:57 +00:00
Load each module and skin through securecallfunction so one error no longer stops the rest from loading
This commit is contained in:
@@ -345,14 +345,16 @@ function pfUI:RegisterSkin(name, func, arg3)
|
||||
end
|
||||
end
|
||||
|
||||
-- an error in one module or skin goes to the error handler without
|
||||
-- stopping the ones that load after it
|
||||
function pfUI:LoadModule(m)
|
||||
setfenv(pfUI.module[m], pfUI:GetEnvironment())
|
||||
pfUI.module[m]()
|
||||
securecallfunction(pfUI.module[m])
|
||||
end
|
||||
|
||||
function pfUI:LoadSkin(s)
|
||||
setfenv(pfUI.skin[s], pfUI:GetEnvironment())
|
||||
pfUI.skin[s]()
|
||||
securecallfunction(pfUI.skin[s])
|
||||
end
|
||||
|
||||
pfUI:SetScript("OnEvent", function()
|
||||
|
||||
Reference in New Issue
Block a user