From 6ae863148f8b4326c31149c7116452cfe2c885ee Mon Sep 17 00:00:00 2001 From: kleph Date: Wed, 8 Apr 2020 19:25:29 +0200 Subject: [PATCH] Fix behaviour when specifying only hour --- beer/beer.py | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/beer/beer.py b/beer/beer.py index a7ddf54..4e1ea19 100755 --- a/beer/beer.py +++ b/beer/beer.py @@ -17,8 +17,10 @@ def index(hours=None, minutes=None): """ main and only app """ if not hours: hours = 17 - if not minutes: + if hours and not minutes: minutes = 30 + else: + minutes = 0 data = render_template('beer.html', hours=hours, minutes=minutes) return data