mirror of
https://github.com/parnic/LibDogTag-3.0.git
synced 2025-06-16 20:20:14 -05:00
- add :ClearNamespace, which will be used by sublibraries when upgrading.
This commit is contained in:
@ -468,4 +468,16 @@ function DogTag:ADDON_LOADED()
|
||||
end
|
||||
end
|
||||
|
||||
function DogTag:ClearNamespace(namespace)
|
||||
if type(namespace) ~= "string" then
|
||||
error(("Bad argument #2 to `ClearNamespace'. Expected %q, got %q"):format("string", type(namespace)), 2)
|
||||
end
|
||||
Tags[namespace] = nil
|
||||
AddonFinders[namespace] = nil
|
||||
self.EventHandlers[namespace] = nil
|
||||
self.TimerHandlers[namespace] = nil
|
||||
clearCodes(namespace)
|
||||
collectgarbage('collect')
|
||||
end
|
||||
|
||||
end
|
||||
|
Reference in New Issue
Block a user