Rollback attempt at fixing autoplay

This commit is contained in:
dmunozv04
2023-11-03 15:49:16 +01:00
parent d72b24c95b
commit 262e3c606d

View File

@@ -78,10 +78,11 @@ class YtLoungeApi(pyytlounge.YtLoungeApi):
self.volume_state = args[0] self.volume_state = args[0]
pass pass
# Gets segments for the next video before it starts playing # Gets segments for the next video before it starts playing
elif event_type == "autoplayUpNext": # Comment "fix" since it doesn't seem to work
if len(args) > 0 and (vid_id := args[0]["videoId"]): # if video id is not empty # elif event_type == "autoplayUpNext":
print(f"Getting segments for next video: {vid_id}") # if len(args) > 0 and (vid_id := args[0]["videoId"]): # if video id is not empty
create_task(self.api_helper.get_segments(vid_id)) # print(f"Getting segments for next video: {vid_id}")
# create_task(self.api_helper.get_segments(vid_id))
# #Used to know if an ad is skippable or not # #Used to know if an ad is skippable or not
elif event_type == "adPlaying": elif event_type == "adPlaying":