mirror of
https://github.com/PHIDIAS0303/ExpCluster.git
synced 2026-11-17 00:40:42 +09:00
Most bugs caught
This commit is contained in:
1 parent
ba3a01f9d6
commit
d2f4ed53ab
20 files changed
+140
-60
No files matched your search
@@ -147,7 +147,7 @@ function commands.get_commands(player)
|
||||
if not player then return error('Invalid player',2) end
|
||||
for name,data in pairs(data) do
|
||||
if #middleware > 0 then for _,callback in pairs(middleware) do
|
||||
local success, err = pcall(callback,player_name,command.name,command)
|
||||
local success, err = pcall(callback,player,name,data)
|
||||
if not success then error(err)
|
||||
elseif err then table.insert(commands,data) end
|
||||
end elseif data.default_admin_only == true and player.admin then table.insert(commands,data) end
|
||||
|
||||
Reference in new issue
Block a user