From 050dbd30d3fbe4e1835cbcba8c605c943cb3e138 Mon Sep 17 00:00:00 2001 From: Joerg Thalheim Date: Tue, 28 Nov 2017 18:18:59 +0000 Subject: [PATCH] Allow widget to be a function again This was broke by async support. --- init.lua | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/init.lua b/init.lua index c53254b..473e381 100644 --- a/init.lua +++ b/init.lua @@ -82,7 +82,7 @@ local function update(widget, reg, disablecache) if c and c.time and c.data and t < c.time+reg.timer and not disablecache then return update_value(format_data(c.data)) elseif reg.wtype then - if reg.wtype.async then + if type(reg.wtype) == "table" and reg.wtype.async then if not reg.lock then reg.lock = true return reg.wtype.async(reg.format,