diff options
| author | Samantaz Fox <coding@samantaz.fr> | 2021-10-07 22:21:40 +0200 |
|---|---|---|
| committer | Samantaz Fox <coding@samantaz.fr> | 2021-10-18 16:12:17 +0200 |
| commit | f7f09109531979de6e8bc7789b56b3e69b818b6b (patch) | |
| tree | 110e1751c9453ecf640537efbbd2a9a33cbe34f6 /src | |
| parent | d300797e229e12973559334cc53a17f79a27ac90 (diff) | |
| download | invidious-f7f09109531979de6e8bc7789b56b3e69b818b6b.tar.gz invidious-f7f09109531979de6e8bc7789b56b3e69b818b6b.tar.bz2 invidious-f7f09109531979de6e8bc7789b56b3e69b818b6b.zip | |
Remove fetch_continuation_token(): dead code
Diffstat (limited to 'src')
| -rw-r--r-- | src/invidious/helpers/helpers.cr | 18 |
1 files changed, 0 insertions, 18 deletions
diff --git a/src/invidious/helpers/helpers.cr b/src/invidious/helpers/helpers.cr index 968062d6..baf82740 100644 --- a/src/invidious/helpers/helpers.cr +++ b/src/invidious/helpers/helpers.cr @@ -270,24 +270,6 @@ def extract_selected_tab(tabs) return selected_target = tabs.as_a.select(&.["tabRenderer"]?.try &.["selected"].as_bool)[0]["tabRenderer"] end -def fetch_continuation_token(items : Array(JSON::Any)) - # Fetches the continuation token from an array of items - return items.last["continuationItemRenderer"]? - .try &.["continuationEndpoint"]["continuationCommand"]["token"].as_s -end - -def fetch_continuation_token(initial_data : Hash(String, JSON::Any)) - # Fetches the continuation token from initial data - if initial_data["onResponseReceivedActions"]? - continuation_items = initial_data["onResponseReceivedActions"][0]["appendContinuationItemsAction"]["continuationItems"] - else - tab = extract_selected_tab(initial_data["contents"]["twoColumnBrowseResultsRenderer"]["tabs"]) - continuation_items = tab["content"]["sectionListRenderer"]["contents"][0]["itemSectionRenderer"]["contents"][0]["gridRenderer"]["items"] - end - - return fetch_continuation_token(continuation_items.as_a) -end - def check_enum(db, enum_name, struct_type = nil) return # TODO |
