mirror of
https://github.com/etlegacy/wolfadmin.git
synced 2024-11-21 20:01:18 +00:00
Fixed suspicious globals (fixes #75)
This commit is contained in:
parent
2c32671304
commit
6eeec2d20a
2 changed files with 4 additions and 0 deletions
|
@ -57,6 +57,8 @@ end
|
|||
commands.addadmin("setlevel", commandSetLevel, auth.PERM_SETLEVEL, "sets the admin level of a player", "^9[^3name|slot#^9] ^9[^3level^9]", true, (settings.get("g_standalone") == 1))
|
||||
|
||||
function commandSetLevel(clientId, command, victim, level)
|
||||
local cmdClient
|
||||
|
||||
if victim == nil then
|
||||
et.trap_SendConsoleCommand(et.EXEC_APPEND, "csay "..clientId.." \"^dsetlevel usage: "..commands.getadmin("setlevel")["syntax"].."\";")
|
||||
|
||||
|
|
|
@ -53,6 +53,8 @@ end
|
|||
commands.addadmin("warn", commandWarn, auth.PERM_WARN, "warns a player by displaying the reason", "^9[^3name|slot#^9] ^9[^3reason^9]", true, (settings.get("g_standalone") == 1 or settings.get("g_playerHistory") == 0))
|
||||
|
||||
function commandWarn(clientId, command, victim, ...)
|
||||
local cmdClient
|
||||
|
||||
if not victim or not ... then
|
||||
et.trap_SendConsoleCommand(et.EXEC_APPEND, "csay "..clientId.." \"^dwarn usage: "..commands.getadmin("warn")["syntax"].."\";")
|
||||
|
||||
|
|
Loading…
Reference in a new issue