From 50c888f9a7a8acd6ac06889330ffce9b5f9309c7 Mon Sep 17 00:00:00 2001 From: Ben Busby Date: Thu, 1 Apr 2021 10:21:59 -0400 Subject: [PATCH] Revert heroku app https upgrade fix --- app/utils/search.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/app/utils/search.py b/app/utils/search.py index 0a944d0..b71e6dd 100644 --- a/app/utils/search.py +++ b/app/utils/search.py @@ -25,7 +25,7 @@ def needs_https(url: str) -> bool: """ https_only = bool(os.getenv('HTTPS_ONLY', 0)) - is_heroku = '.herokuapp.com' in url + is_heroku = url.endswith('.herokuapp.com') is_http = url.startswith('http://') return (is_heroku and is_http) or (https_only and is_http)