From 51dcbcbf516efa4ec5177a20f2018b3266985a52 Mon Sep 17 00:00:00 2001 From: syeopite Date: Tue, 19 Sep 2023 13:19:48 -0700 Subject: [PATCH] Properly camelcase auto gen chapters attribute --- src/invidious/videos.cr | 2 +- src/invidious/videos/parser.cr | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/src/invidious/videos.cr b/src/invidious/videos.cr index 2b32ef96..d1b9d8bb 100644 --- a/src/invidious/videos.cr +++ b/src/invidious/videos.cr @@ -155,7 +155,7 @@ struct Video end def automatically_generated_chapters? : Bool? - return @info["AutoGeneratedChapters"]?.try &.as_bool + return @info["autoGeneratedChapters"]?.try &.as_bool end def hls_manifest_url : String? diff --git a/src/invidious/videos/parser.cr b/src/invidious/videos/parser.cr index 9b74d911..5feb02e4 100644 --- a/src/invidious/videos/parser.cr +++ b/src/invidious/videos/parser.cr @@ -489,7 +489,7 @@ def parse_video_info(video_id : String, player_response : Hash(String, JSON::Any "authorVerified" => JSON::Any.new(author_verified || false), "subCountText" => JSON::Any.new(subs_text || "-"), - "AutoGeneratedChapters" => JSON::Any.new(chapters_auto_generated), + "autoGeneratedChapters" => JSON::Any.new(chapters_auto_generated), "chapters" => JSON::Any.new(chapters_array), }