make functions local
This commit is contained in:
parent
d46954629f
commit
b24aa5d041
|
@ -61,12 +61,12 @@ local icon_map = {
|
||||||
}
|
}
|
||||||
|
|
||||||
-- handy function to convert temperature from Kelvin to Celcius
|
-- handy function to convert temperature from Kelvin to Celcius
|
||||||
function to_celcius(kelvin)
|
local function to_celcius(kelvin)
|
||||||
return math.floor(tonumber(kelvin) - 273.15)
|
return math.floor(tonumber(kelvin) - 273.15)
|
||||||
end
|
end
|
||||||
|
|
||||||
-- Return wind direction as a string.
|
-- Return wind direction as a string.
|
||||||
function to_direction(degrees)
|
local function to_direction(degrees)
|
||||||
local directions = {
|
local directions = {
|
||||||
{ "N", 348.75, 360 },
|
{ "N", 348.75, 360 },
|
||||||
{ "N", 0, 11.25 },
|
{ "N", 0, 11.25 },
|
||||||
|
|
Loading…
Reference in New Issue