add migration for old networks

This commit is contained in:
theFox6 2023-10-14 22:01:35 +02:00
parent 6428b89a84
commit 75e5a237f2
No known key found for this signature in database
GPG Key ID: 810803FF29A86CCC

@ -203,6 +203,8 @@ microexpansion.register_node("security", {
if fields.logout then if fields.logout then
meta:set_string("formspec", security_formspec(pos)) meta:set_string("formspec", security_formspec(pos))
elseif fields.login or fields.back then elseif fields.login or fields.back then
-- carry over networks from old versions
net:fallback_access()
meta:set_string("formspec", security_formspec(pos, name)) meta:set_string("formspec", security_formspec(pos, name))
elseif fields.search or fields.key_enter_field == "filter" then elseif fields.search or fields.key_enter_field == "filter" then
meta:set_string("formspec", security_formspec(pos, name), false, fields.filter) meta:set_string("formspec", security_formspec(pos, name), false, fields.filter)