Update community post API

This commit is contained in:
syeopite 2021-07-27 23:41:20 -07:00
parent e8dc337306
commit 2a32f84332
No known key found for this signature in database
GPG key ID: 6FA616E5A5294A82
2 changed files with 22 additions and 8 deletions

View file

@ -235,7 +235,21 @@ module Invidious::Routes::API::V1::Channels
# sort_by = env.params.query["sort_by"]?.try &.downcase # sort_by = env.params.query["sort_by"]?.try &.downcase
begin begin
# fetch_channel_community(ucid, continuation, locale, format, thin_mode) if continuation
results = fetch_channel_community(ucid, continuation)
else
results = fetch_channel_community(ucid)
end
JSON.build do |json|
json.array do
results[0].each do |item|
item.to_json(locale, json)
end
json.string results[1]
end
end
rescue ex rescue ex
return error_json(500, ex) return error_json(500, ex)
end end