[Hooks] Removed unused variable.

This commit is contained in:
FireSiku 2019-01-16 19:24:07 -05:00
parent 630893203f
commit fd5a3d3afc

View file

@ -289,6 +289,8 @@ local function generic_hook(mod, obj, method, handler, func_name)
mod:error("(%s): trying to hook %s (a %s), not a function.", func_name, method, type(orig))
return
end
-- Edge Case: If someone hooks a copy of a function after its been hooked, point it back in the right direction
if _registry.uids[orig] then
orig = _registry.uids[orig]
end
@ -328,8 +330,6 @@ local function generic_hook_toggle(mod, obj, method, enabled_state)
end
end
local orig = get_orig_function(obj, method)
if _registry[mod][obj[method]] then
_registry[mod][obj[method]].active = enabled_state
else