X-Git-Url: https://git.madduck.net/etc/awesome.git/blobdiff_plain/6cce5b6fe11fe8c69b08140d645c604fef59e42a..32eddd514f8ccc35eeaa128a441f6a47708e6a04:/widgets/temp.lua?ds=inline diff --git a/widgets/temp.lua b/widgets/temp.lua index 9c82b8b..e769b25 100644 --- a/widgets/temp.lua +++ b/widgets/temp.lua @@ -26,7 +26,6 @@ local function worker(args) function update() local f = io.open(tempfile) - local coretemp_now if f then coretemp_now = tonumber(f:read("*all")) / 1000 f:close() @@ -40,7 +39,7 @@ local function worker(args) newtimer("coretemp", timeout, update) - return temp.widget + return setmetatable(temp, { __index = temp.widget }) end return setmetatable(temp, { __call = function(_, ...) return worker(...) end })