mirror of
https://github.com/pretix/pretix.git
synced 2026-04-25 23:42:32 +00:00
fix code-style
This commit is contained in:
@@ -531,7 +531,11 @@ def add_events_for_days(request, baseqs, before, after, ebd, timezones):
|
||||
date_to = event.date_to.astimezone(tz).date()
|
||||
d = max(date_from, before.date())
|
||||
while d <= date_to and d <= after.date():
|
||||
if date_to != date_from and datetime_to.hour == 0 and datetime_to.minute == 0 and datetime_to.second == 0 and (d == date_to or d == after.date()):
|
||||
if (
|
||||
date_to != date_from
|
||||
and datetime_to.hour == 0 and datetime_to.minute == 0 and datetime_to.second == 0
|
||||
and (d == date_to or d == after.date())
|
||||
):
|
||||
# multi-day event, but special case ends midnight, so do not show on the day it ends
|
||||
break
|
||||
first = d == date_from
|
||||
@@ -662,7 +666,11 @@ def add_subevents_for_days(qs, before, after, ebd, timezones, sales_channel, eve
|
||||
date_to = se.date_to.astimezone(tz).date()
|
||||
d = max(date_from, before.date())
|
||||
while d <= date_to and d <= after.date():
|
||||
if date_to != date_from and datetime_to.hour == 0 and datetime_to.minute == 0 and datetime_to.second == 0 and (d == date_to or d == after.date()):
|
||||
if (
|
||||
date_to != date_from
|
||||
and datetime_to.hour == 0 and datetime_to.minute == 0 and datetime_to.second == 0
|
||||
and (d == date_to or d == after.date())
|
||||
):
|
||||
# multi-day event, but special case ends midnight, so do not show on the day it ends
|
||||
break
|
||||
first = d == date_from
|
||||
|
||||
Reference in New Issue
Block a user