Less indentation

merge-requests/30/head
Bob Mottram 2024-07-16 10:55:34 +01:00
parent 44bff188c2
commit 0a34a1d00f
1 changed files with 28 additions and 26 deletions

View File

@ -368,8 +368,11 @@ def html_calendar(person_cache: {}, translate: {},
if '?' in actor:
first = True
for part in actor.split('?'):
if not first:
if '=' in part:
if first:
first = False
continue
if '=' not in part:
continue
if part.split('=')[0] == 'year':
num_str = part.split('=')[1]
if len(num_str) <= 5:
@ -393,7 +396,6 @@ def html_calendar(person_cache: {}, translate: {},
bool_str = part.split('=')[1]
if bool_str.lower().startswith('t'):
only_show_reminders = True
first = False
actor = actor.split('?')[0]
curr_date = datetime.now()