added int cast

This commit is contained in:
aj 2019-08-03 19:41:23 +01:00
parent a93ea5c27d
commit cc390e2088

View File

@ -55,7 +55,7 @@ def run_user_playlist(username, playlist_name):
processors.append(SortReverseReleaseDate()) processors.append(SortReverseReleaseDate())
if playlist_dict['type'] == 'recents': if playlist_dict['type'] == 'recents':
boundary_date = datetime.datetime.now() - datetime.timedelta(days=playlist_dict['day_boundary']) boundary_date = datetime.datetime.now() - datetime.timedelta(days=int(playlist_dict['day_boundary']))
tracks = engine.get_recent_playlist(boundary_date, playlist_dict['parts'], processors) tracks = engine.get_recent_playlist(boundary_date, playlist_dict['parts'], processors)
else: else:
tracks = engine.make_playlist(playlist_dict['parts'], processors) tracks = engine.make_playlist(playlist_dict['parts'], processors)