From 0461aab1c18d148bb017a8b33edd8982b92112af Mon Sep 17 00:00:00 2001 From: mutantmonkey Date: Sun, 6 Nov 2011 01:42:19 -0500 Subject: [PATCH] tfw: handle negative temps --- modules/tfw.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/modules/tfw.py b/modules/tfw.py index 1c79de1..fde0f5d 100755 --- a/modules/tfw.py +++ b/modules/tfw.py @@ -43,7 +43,7 @@ def tfw(phenny, input, fahrenheit=False, celsius=False): # temperature is everything up to first
tempt = "" for c in main[0].text: - if c.isdigit(): + if c.isdigit() or c == '-': tempt += c temp = int(tempt) deg = chr(176)