From d739ef8fd340149a0b1a2371ffd419c9723ce4f4 Mon Sep 17 00:00:00 2001 From: Omar Roth Date: Fri, 2 Nov 2018 08:26:35 -0500 Subject: [PATCH] Add fix for videos without keywords --- src/invidious/videos.cr | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/src/invidious/videos.cr b/src/invidious/videos.cr index d21806d5..1c0ad35a 100644 --- a/src/invidious/videos.cr +++ b/src/invidious/videos.cr @@ -263,7 +263,10 @@ class Video end def keywords - return self.player_response["videoDetails"]["keywords"].as_a + keywords = self.player_response["videoDetails"]["keywords"]?.try &.as_a + keywords ||= [] of String + + return keywords end def fmt_stream(decrypt_function)