aboutsummaryrefslogtreecommitdiff
path: root/cpu.lua
diff options
context:
space:
mode:
Diffstat (limited to 'cpu.lua')
-rw-r--r--cpu.lua3
1 files changed, 3 insertions, 0 deletions
diff --git a/cpu.lua b/cpu.lua
index 5112253..7f0a006 100644
--- a/cpu.lua
+++ b/cpu.lua
@@ -8,6 +8,7 @@ local type = type
local pairs = pairs
local ipairs = ipairs
local io = { open = io.open }
+local setmetatable = setmetatable
local math = { floor = math.floor }
local table = { insert = table.insert }
local helpers = require("vicious.helpers")
@@ -93,3 +94,5 @@ function worker(format, padding)
return cpu_usage
end
-- }}}
+
+setmetatable(_M, { __call = function(_, ...) return worker(...) end })