fix(nix-monitor): fix some warnings

This commit is contained in:
avivbintangaringga
2026-07-16 16:04:09 +07:00
parent c7046594f9
commit 132575905e
2 changed files with 5 additions and 7 deletions
+3 -5
View File
@@ -11,16 +11,14 @@ function getState(key)
end
function displayWidget(glyph: string, text: string, color: string?)
if color == nil then
color = "on_surface"
end
local _color = color or "on_surface"
if cfg("colorize_text") then
barWidget.setColor(color)
barWidget.setColor(_color)
end
if cfg("colorize_glyph") then
barWidget.setGlyphColor(color)
barWidget.setGlyphColor(_color)
end
if cfg("show_glyph") then
+2 -2
View File
@@ -234,7 +234,7 @@ function onCancelClicked()
end
function onUpdateClicked()
command = cfg("update_command")
local command = cfg("update_command")
if command == "" then
noctalia.notifyError(tr("notification.update_command_is_empty"))
return
@@ -249,7 +249,7 @@ function onUpdateClicked()
end
function onCleanClicked()
command = cfg("clean_command")
local command = cfg("clean_command")
if command == "" then
noctalia.notifyError(tr("notification.clean_command_is_empty"))
return