From 65a21b2c2d8705ec75d33649c3e7ac05897d0a62 Mon Sep 17 00:00:00 2001 From: Igor Chubin Date: Wed, 28 Aug 2019 13:57:10 +0200 Subject: [PATCH] initial support of subviews --- lib/wttr_line.py | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/lib/wttr_line.py b/lib/wttr_line.py index 9c8a441..5ede450 100644 --- a/lib/wttr_line.py +++ b/lib/wttr_line.py @@ -234,10 +234,11 @@ def format_weather_data(format_line, location, override_location, full_address, if format_line == "j1": return render_json(data['data']) - if format_line == "v2": + if format_line[:2] == "v2": return spark.main(location, - override_location=override_location, - full_address=full_address, data=data) + override_location=override_location, + full_address=full_address, data=data, + view=format_line) current_condition = data['data']['current_condition'][0] current_condition['location'] = location