From d38658620192a61bbb67c3978a107ff4cc8ed89b Mon Sep 17 00:00:00 2001 From: lhofhansl Date: Sat, 7 Oct 2017 06:12:09 -0700 Subject: Do not grant all privs to the admin - changes game behavior (#6460) * Do not grant all privs to admins. * Default give_to_admin to give_to_singleplayer --- builtin/game/auth.lua | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) (limited to 'builtin/game/auth.lua') diff --git a/builtin/game/auth.lua b/builtin/game/auth.lua index 4d5178ba7..bf5bd19a8 100644 --- a/builtin/game/auth.lua +++ b/builtin/game/auth.lua @@ -83,7 +83,9 @@ core.builtin_auth_handler = { -- For the admin, give everything elseif name == core.settings:get("name") then for priv, def in pairs(core.registered_privileges) do - privileges[priv] = true + if def.give_to_admin then + privileges[priv] = true + end end end -- All done -- cgit v1.2.3