diff options
Diffstat (limited to 'widgets/cpufreq.lua')
-rw-r--r-- | widgets/cpufreq.lua | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/widgets/cpufreq.lua b/widgets/cpufreq.lua index 7f60f5a..f7c6a27 100644 --- a/widgets/cpufreq.lua +++ b/widgets/cpufreq.lua @@ -16,8 +16,10 @@ module("vicious.widgets.cpufreq") -- {{{ CPU frequency widget type -local function worker(format, cpuid) - local cpufreq = helpers.pathtotable("/sys/devices/system/cpu/"..cpuid.."/cpufreq") +local function worker(format, warg) + if not warg then return end + + local cpufreq = helpers.pathtotable("/sys/devices/system/cpu/"..warg.."/cpufreq") local governor_state = { ["ondemand\n"] = "↯", ["powersave\n"] = "⌁", |