diff --git a/helpers.lua b/helpers.lua index 43474b6..7a69d72 100644 --- a/helpers.lua +++ b/helpers.lua @@ -10,12 +10,12 @@ ----------------------------------------------------- local is_46 = minetest.has_feature("add_entity_with_staticdata") -if is_46 then - get_minetest_config = function( key ) - minetest.settings:get( key ) +function get_minetest_config( key ) + if is_46 then + return minetest.settings:get( key ) + else + return core.setting_get( key ) -- backwards compatibility end -else - get_minetest_config = core.setting_get -- backwards compatibility end function convert_ipv4( str )