From d7fba610a118a5477d34b3ae613da04825065008 Mon Sep 17 00:00:00 2001 From: Dorian Wouters Date: Tue, 23 Aug 2016 14:31:59 +0200 Subject: [PATCH] Don't use auth_table, use get_auth_handler().get_auth instead No guarantee is made auth_table contains auth entries or even exists. Using this table directly is incompatible with auth handlers that don't cache auth entries (e.g. when they are stored in an SQL database supposed to be concurrently accessed and modified). --- internal.lua | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/internal.lua b/internal.lua index 45d7f5f..2da3228 100644 --- a/internal.lua +++ b/internal.lua @@ -2,7 +2,7 @@ minetest.register_privilege("megabuilder","Can protect an infinite amount of areas.") function areas:player_exists(name) - return minetest.auth_table[name] ~= nil + return minetest.get_auth_handler().get_auth(name) ~= nil end -- Save the areas table to a file