summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorstreetturtle <streetturtle@gmail.com>2018-03-24 21:03:36 -0400
committerstreetturtle <streetturtle@gmail.com>2018-03-24 21:03:36 -0400
commitb24aa5d041bfacbea5190bb778a5a44c328d3ee9 (patch)
tree9374937f3c41688a7bdcef9c027b025b2d6657ee
parentd46954629f14a9d4cebd18ac7b25046282487f97 (diff)
make functions local
-rw-r--r--weather-widget/weather.lua4
1 files changed, 2 insertions, 2 deletions
diff --git a/weather-widget/weather.lua b/weather-widget/weather.lua
index 43ce974..a279d99 100644
--- a/weather-widget/weather.lua
+++ b/weather-widget/weather.lua
@@ -61,12 +61,12 @@ local icon_map = {
}
-- 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)
end
-- Return wind direction as a string.
-function to_direction(degrees)
+local function to_direction(degrees)
local directions = {
{ "N", 348.75, 360 },
{ "N", 0, 11.25 },