diff options
author | Weblate <42@minetest.ru> | 2013-03-31 12:27:05 +0200 |
---|---|---|
committer | Weblate <42@minetest.ru> | 2013-03-31 12:27:05 +0200 |
commit | 319662c0ed047c6604d802336b54c325867fcab9 (patch) | |
tree | 5e30a3f9568ddafc41420f8d5bedc1c5dacce6e2 /builtin | |
parent | 5b597a6bfacda92006d153159929c8d777b4df89 (diff) | |
parent | a2e5706661b2aa4796c01a251bc05ae3eb93f9d6 (diff) | |
download | minetest-319662c0ed047c6604d802336b54c325867fcab9.tar.gz minetest-319662c0ed047c6604d802336b54c325867fcab9.tar.bz2 minetest-319662c0ed047c6604d802336b54c325867fcab9.zip |
Merge remote branch 'origin/master'
Diffstat (limited to 'builtin')
-rw-r--r-- | builtin/chatcommands.lua | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/builtin/chatcommands.lua b/builtin/chatcommands.lua index f41f9afe4..4b09f7b2b 100644 --- a/builtin/chatcommands.lua +++ b/builtin/chatcommands.lua @@ -116,6 +116,9 @@ minetest.register_chatcommand("grant", { if not grantname or not grantprivstr then minetest.chat_send_player(name, "Invalid parameters (see /help grant)") return + elseif not minetest.auth_table[grantname] then + minetest.chat_send_player(name, "Player "..grantname.." does not exist.") + return end local grantprivs = minetest.string_to_privs(grantprivstr) if grantprivstr == "all" then @@ -159,6 +162,9 @@ minetest.register_chatcommand("revoke", { if not revokename or not revokeprivstr then minetest.chat_send_player(name, "Invalid parameters (see /help revoke)") return + elseif not minetest.auth_table[revokename] then + minetest.chat_send_player(name, "Player "..revokename.." does not exist.") + return end local revokeprivs = minetest.string_to_privs(revokeprivstr) local privs = minetest.get_player_privs(revokename) |