not needed

I discovered how the migration is to work :)
This commit is contained in:
SwissalpS 2019-11-12 18:29:01 +01:00
parent 8355721864
commit 12ef7a5d65
3 changed files with 0 additions and 20 deletions

View File

@ -31,7 +31,6 @@ local MP = minetest.get_modpath("beerchat")
dofile(MP.."/format_message.lua")
dofile(MP.."/hooks.lua")
dofile(MP.."/storage.lua")
dofile(MP.."/moveAttributesToMeta.lua")
dofile(MP.."/session.lua")
dofile(MP.."/pm.lua")
dofile(MP.."/hash.lua")

View File

@ -1,18 +0,0 @@
-- transfer user information from depricated attributes to player metaRef
-- called when player joins
beerchat.moveAttributesToMeta = function(player)
local meta = player:get_meta()
local str = player:get_attribute("beerchat:channels")
if str and str ~= "" then
meta:set_string("beerchat:channels", str)
player:set_attribute("beerchat:channels", nil)
end
local current_channel = player:get_attribute("beerchat:current_channel")
if current_channel and current_channel ~= "" then
meta:set_string("beerchat:current_channel", current_channel)
player:set_attribute("beerchat:current_channel", nil)
end
end -- moveAttributesToMeta

View File

@ -1,7 +1,6 @@
minetest.register_on_joinplayer(function(player)
beerchat.moveAttributesToMeta(player)
local str = player:get_attribute("beerchat:channels")
if str and str ~= "" then
beerchat.playersChannels[player:get_player_name()] = {}