format bugfix

This commit is contained in:
Baipyrus 2023-10-29 15:13:10 +01:00
parent 0d7cb37b5e
commit f4bc968c8a

View File

@ -40,7 +40,7 @@ end
-- format percentages as number with two decimals and padded unit
function format_percent(options, number)
return string.format('%.2f', number * 100) .. ' % ' .. string.rep(' ', #options.unit)
return string.format('%.2f', number * 100) .. ' % ' .. string.rep(' ', #options.unit)
end
-- format temperature as number with two decimals and padded unit
@ -52,7 +52,7 @@ function format_temp(options, number)
else temperature = string.format('%.2f', temperature) end
-- build string
return temperature .. 'K ' .. string.rep(' ', #options.unit)
return temperature .. 'K ' .. string.rep(' ', #options.unit)
end
function find_peripheral_component(name)