You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
22 lines
385 B
22 lines
385 B
3 years ago
|
require "sys"
|
||
|
|
||
|
local loader = {}
|
||
|
|
||
|
loader.load = function(path)
|
||
|
if global_config["FeatureToggle"]["EnableShowInternalAttributeId"] ~= "1" then
|
||
|
log.warn('failed: disable')
|
||
|
return false
|
||
|
end
|
||
|
loader.dll = sys.load_library(path)
|
||
|
return loader.dll ~= nil
|
||
|
end
|
||
|
|
||
|
loader.unload = function()
|
||
|
if loader.dll then
|
||
|
sys.unload_library(loader.dll)
|
||
|
loader.dll = nil
|
||
|
end
|
||
|
end
|
||
|
|
||
|
return loader
|