mirror of
				https://github.com/luanti-org/minetest_game.git
				synced 2025-11-04 09:15:29 +01:00 
			
		
		
		
	sethome: Do not write empty homes file
This commit is contained in:
		@@ -32,6 +32,9 @@ sethome.set = function(name, pos)
 | 
			
		||||
	player:set_attribute("sethome:home", minetest.pos_to_string(pos))
 | 
			
		||||
 | 
			
		||||
	-- remove `name` from the old storage file
 | 
			
		||||
	if not homepos[name] then
 | 
			
		||||
		return true
 | 
			
		||||
	end
 | 
			
		||||
	local data = {}
 | 
			
		||||
	local output = io.open(homes_file, "w")
 | 
			
		||||
	if output then
 | 
			
		||||
 
 | 
			
		||||
		Reference in New Issue
	
	Block a user