Fix typo (GH#7421)
authornumber Zero <silverunicorn2011@yandex.ru>
Sat, 9 Jun 2018 21:52:30 +0000 (00:52 +0300)
committersfan5 <sfan5@live.de>
Sun, 10 Jun 2018 08:34:13 +0000 (10:34 +0200)
builtin/game/register.lua

index 6a7c4747f9b9e0dbc2ab973ae49990615f4a3d43..3edab0471a6dbc7c2c47126c0307db78f34393ef 100644 (file)
@@ -445,7 +445,7 @@ end
 function core.run_priv_callbacks(name, priv, caller, method)
        local def = core.registered_privileges[priv]
        if not def or not def["on_" .. method] or
-                       not def[priv]["on_" .. method](name, caller) then
+                       not def["on_" .. method](name, caller) then
                for _, func in ipairs(core["registered_on_priv_" .. method]) do
                        if not func(name, caller, priv) then
                                break