diff options
| author | Émilien Devos <contact@emiliendevos.be> | 2021-08-12 19:14:30 +0200 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2021-08-12 19:14:30 +0200 |
| commit | 88c5e3b6fad59e8cc4f506db665b848d7dc78242 (patch) | |
| tree | da7fe294780724b3b9b79e7a2f36183c8eadff61 /src/invidious.cr | |
| parent | 2fdb2c7c9afcfd49eaa846983569ebe02947e58a (diff) | |
| download | invidious-88c5e3b6fad59e8cc4f506db665b848d7dc78242.tar.gz invidious-88c5e3b6fad59e8cc4f506db665b848d7dc78242.tar.bz2 invidious-88c5e3b6fad59e8cc4f506db665b848d7dc78242.zip | |
Use the new youtube api for comments (#2217)
* use the new youtube api for comments
* remove PG_DB & action parameter + allow force region
* support new comments data with onResponseReceivedEndpoints
Diffstat (limited to 'src/invidious.cr')
| -rw-r--r-- | src/invidious.cr | 5 |
1 files changed, 1 insertions, 4 deletions
diff --git a/src/invidious.cr b/src/invidious.cr index 1d183637..5b61b895 100644 --- a/src/invidious.cr +++ b/src/invidious.cr @@ -1873,9 +1873,6 @@ get "/api/v1/comments/:id" do |env| format = env.params.query["format"]? format ||= "json" - action = env.params.query["action"]? - action ||= "action_get_comments" - continuation = env.params.query["continuation"]? sort_by = env.params.query["sort_by"]?.try &.downcase @@ -1883,7 +1880,7 @@ get "/api/v1/comments/:id" do |env| sort_by ||= "top" begin - comments = fetch_youtube_comments(id, PG_DB, continuation, format, locale, thin_mode, region, sort_by: sort_by, action: action) + comments = fetch_youtube_comments(id, continuation, format, locale, thin_mode, region, sort_by: sort_by) rescue ex next error_json(500, ex) end |
