Skip to content

Commit

Permalink
Add support for comments under controversial videos
Browse files Browse the repository at this point in the history
  • Loading branch information
omarroth committed Sep 13, 2018
1 parent a546686 commit d4ee786
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/invidious.cr
Original file line number Diff line number Diff line change
Expand Up @@ -1803,7 +1803,7 @@ get "/api/v1/comments/:id" do |env|
if source == "youtube"
client = make_client(YT_URL)
headers = HTTP::Headers.new
html = client.get("/watch?v=#{id}&disable_polymer=1")
html = client.get("/watch?v=#{id}&bpctr=#{Time.new.epoch + 2000}&disable_polymer=1")

headers["cookie"] = html.cookies.add_request_headers(headers)["cookie"]
headers["content-type"] = "application/x-www-form-urlencoded"
Expand Down

0 comments on commit d4ee786

Please sign in to comment.