From 7402f30c3a5267f7c6c909261bd272ae09ab231c Mon Sep 17 00:00:00 2001 From: Tim Date: Wed, 19 Aug 2015 17:02:01 +0200 Subject: [PATCH] simplify calendar construction --- homedecor/office.lua | 6 +----- 1 file changed, 1 insertion(+), 5 deletions(-) diff --git a/homedecor/office.lua b/homedecor/office.lua index 9e5d1e38..2d4cbaa5 100644 --- a/homedecor/office.lua +++ b/homedecor/office.lua @@ -78,11 +78,7 @@ homedecor.register("calendar", { groups = {choppy=2,attached_node=1}, legacy_wallmounted = true, sounds = default.node_sound_defaults(), - on_construct = function(pos) - local meta = minetest.get_meta(pos) - local date = os.date("%Y-%m-%d") -- ISO 8601 format - meta:set_string("infotext", "Date (right-click to update):\n"..date) - end, + infotext = "Date (right-click to update):\n" .. os.date("%Y-%m-%d"), -- ISO 8601 format on_rightclick = function(pos, node, clicker) local meta = minetest.get_meta(pos) local date = os.date("%Y-%m-%d")