diff options
| author | Omar Roth <omarroth@hotmail.com> | 2019-02-09 12:28:43 -0600 |
|---|---|---|
| committer | Omar Roth <omarroth@hotmail.com> | 2019-02-09 12:28:43 -0600 |
| commit | 27934dad379682fab59c2be39aac30914cd5a356 (patch) | |
| tree | f5dc09067eeea5fc091afcde167193e413023c99 | |
| parent | 0d509c82ee2d3bba669d1a6c2625b04358cc9d74 (diff) | |
| download | invidious-27934dad379682fab59c2be39aac30914cd5a356.tar.gz invidious-27934dad379682fab59c2be39aac30914cd5a356.tar.bz2 invidious-27934dad379682fab59c2be39aac30914cd5a356.zip | |
Add `region` to `latest_version`
| -rw-r--r-- | src/invidious.cr | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/src/invidious.cr b/src/invidious.cr index 72ac8caf..b210fcc3 100644 --- a/src/invidious.cr +++ b/src/invidious.cr @@ -3662,6 +3662,8 @@ get "/latest_version" do |env| id = env.params.query["id"]? itag = env.params.query["itag"]? + region = env.params.query["region"]? + local = env.params.query["local"]? local ||= "false" local = local == "true" @@ -3670,7 +3672,7 @@ get "/latest_version" do |env| halt env, status_code: 400 end - video = get_video(id, PG_DB, proxies) + video = get_video(id, PG_DB, proxies, region: region) fmt_stream = video.fmt_stream(decrypt_function) adaptive_fmts = video.adaptive_fmts(decrypt_function) |
