From da28d13cb68a47f37829d4c23c824819342eb747 Mon Sep 17 00:00:00 2001
From: echicken <>
Date: Tue, 8 Jan 2019 15:47:04 +0000
Subject: [PATCH] Include units parameter when falling through to assuming
 param is a location name. Otherwise the temperature will appear to be hot hot
 hot but actually be in kelvin.

---
 exec/ircbots/weather/weather_functions.js | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

diff --git a/exec/ircbots/weather/weather_functions.js b/exec/ircbots/weather/weather_functions.js
index 2f7d7ad289..4e0bb7a26f 100644
--- a/exec/ircbots/weather/weather_functions.js
+++ b/exec/ircbots/weather/weather_functions.js
@@ -56,7 +56,8 @@ function get_params(cmd, nick, srv) {
         }
     }
     // Maybe a city name
-    return { q : cmd.join(' ').split(',')[0] };
+    ret.q = cmd.join(' ').split(',')[0];
+    return ret;
 }
 
 function temperature_str(n) {
-- 
GitLab