From b7972bde45e4badc5f21d5b1447f0bede983b128 Mon Sep 17 00:00:00 2001 From: Luke Rogers Date: Thu, 26 Apr 2012 13:17:40 +1200 Subject: [PATCH] Fixed up formatting --- plugins/weather.py | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/plugins/weather.py b/plugins/weather.py index cffd9d2..2192340 100755 --- a/plugins/weather.py +++ b/plugins/weather.py @@ -2,7 +2,7 @@ from util import hook, http def fahrenheit_to_celcius(f): - return (int(f) - 32) / 1.8 + return int(round((int(f) - 32) / 1.8, 0)) @hook.command(autohelp=False) def forecast(inp, nick='', server='', @@ -81,8 +81,8 @@ def weather(inp, nick='', server='', reply=None, db=None, notice=None): info['high_c'] = fahrenheit_to_celcius(info['high']) info['low_c'] = fahrenheit_to_celcius(info['low']) - reply('%(city)s: %(condition)s, %(temp_f)sF/%(temp_c)sC (H:%(high)sF' \ - ' %(high_c)sC, L:%(low)sF, %(low_c)sC), %(humidity)s, ' \ + reply('%(city)s: %(condition)s, %(temp_f)sF/%(temp_c)sC, (H:%(high)sF' \ + ' %(high_c)sC), (L:%(low)sF, %(low_c)sC), %(humidity)s, ' \ '%(wind_condition)s.' % info) if inp and not dontsave: