1
0
Fork 0
mirror of https://github.com/luanti-org/luanti.git synced 2025-08-11 17:51:04 +00:00

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
This commit is contained in:
lhofhansl 2017-10-07 06:12:09 -07:00 committed by Loïc Blot
parent 3c93a56e16
commit d386586201
2 changed files with 11 additions and 1 deletions

View file

@ -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