removed space before km/h (#433)

This commit is contained in:
Igor Chubin 2020-05-01 18:48:19 +02:00
parent 5e2ae43c96
commit 6c7600c309

View File

@ -143,13 +143,13 @@ def render_wind(data, query):
wind_direction = "" wind_direction = ""
if query.get('use_ms_for_wind', False): if query.get('use_ms_for_wind', False):
unit = ' m/s' unit = 'm/s'
wind = u'%s%.1f%s' % (wind_direction, float(data['windspeedKmph'])/36.0*10.0, unit) wind = u'%s%.1f%s' % (wind_direction, float(data['windspeedKmph'])/36.0*10.0, unit)
elif query.get('use_imperial', False): elif query.get('use_imperial', False):
unit = ' mph' unit = 'mph'
wind = u'%s%s%s' % (wind_direction, data['windspeedMiles'], unit) wind = u'%s%s%s' % (wind_direction, data['windspeedMiles'], unit)
else: else:
unit = ' km/h' unit = 'km/h'
wind = u'%s%s%s' % (wind_direction, data['windspeedKmph'], unit) wind = u'%s%s%s' % (wind_direction, data['windspeedKmph'], unit)
return wind return wind