mirror of
https://github.com/ShadowNinja/LuaIRC.git
synced 2025-04-21 03:20:25 +02:00
Pass the connection to hooks
This commit is contained in:
parent
b1cbbf1963
commit
b07166345a
4
init.lua
4
init.lua
@ -66,8 +66,8 @@ meta_preconnect.unhook = meta.unhook
|
||||
function meta:invoke(name, ...)
|
||||
local hooks = self.hooks[name]
|
||||
if hooks then
|
||||
for id,f in pairs(hooks) do
|
||||
if f(...) then
|
||||
for id, f in pairs(hooks) do
|
||||
if f(self, ...) then
|
||||
return true
|
||||
end
|
||||
end
|
||||
|
Loading…
x
Reference in New Issue
Block a user