diff options
author | Jesus E <heckyel@riseup.net> | 2023-05-28 20:42:00 -0400 |
---|---|---|
committer | Jesus E <heckyel@riseup.net> | 2023-05-28 20:42:00 -0400 |
commit | a9a68e7df32340daf8b960a008cd881f6a18a8b5 (patch) | |
tree | a04e84fafd0d71109de9db0ae09729bb3951651a | |
parent | 0f78f07875eba3c029949db408384606c3c802d6 (diff) | |
download | yt-local-a9a68e7df32340daf8b960a008cd881f6a18a8b5.tar.lz yt-local-a9a68e7df32340daf8b960a008cd881f6a18a8b5.tar.xz yt-local-a9a68e7df32340daf8b960a008cd881f6a18a8b5.zip |
go ti video with url
-rw-r--r-- | youtube/search.py | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/youtube/search.py b/youtube/search.py index 7057747..d888c6c 100644 --- a/youtube/search.py +++ b/youtube/search.py @@ -64,6 +64,8 @@ def get_search_page(): query = request.args.get('search_query') or request.args.get('query') if query is None: return flask.render_template('home.html', title='Search') + elif query.startswith("https"): + return flask.redirect(f"/{query}") page = request.args.get("page", "1") autocorrect = int(request.args.get("autocorrect", "1")) |