From 034513718f6c6f13566b860e4e78f19bedf1bfa0 Mon Sep 17 00:00:00 2001 From: b3yond Date: Sat, 14 Apr 2018 16:36:57 +0200 Subject: [PATCH] generate url with dedicated function --- frontend.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/frontend.py b/frontend.py index fecb1df..2fd598d 100755 --- a/frontend.py +++ b/frontend.py @@ -104,7 +104,7 @@ def login_twitter(user): try: consumer_key = config["twitter"]["consumer_key"] consumer_secret = config["twitter"]["consumer_secret"] - callback_url = request.get_header('host') + "/login/twitter/callback" + callback_url = url("/login/twitter/callback") auth = tweepy.OAuthHandler(consumer_key, consumer_secret, callback_url) try: redirect_url = auth.get_authorization_url()