Skip to content

Commit

Permalink
hide items that are not available for catchup
Browse files Browse the repository at this point in the history
  • Loading branch information
emilsvennesson committed Feb 21, 2018
1 parent 9c06857 commit 029b44e
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions resources/lib/addon.py
Original file line number Diff line number Diff line change
Expand Up @@ -336,6 +336,9 @@ def add_tv_event(event):
start_time_obj = helper.vp.parse_datetime(event['epg']['startTime'], localize=True)
event_status = helper.vp.get_event_status(event)

# hide non-available catchup items
if now > helper.vp.parse_datetime(event['system']['catchupAvailability']['end'], localize=True):
return
if date_today == start_time_obj.date():
start_time = '{0} {1}'.format(helper.language(30027), start_time_obj.strftime('%H:%M'))
else:
Expand Down

0 comments on commit 029b44e

Please sign in to comment.