aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorBryan Newbold <bnewbold@archive.org>2019-07-31 17:24:06 -0700
committerBryan Newbold <bnewbold@archive.org>2019-07-31 17:24:06 -0700
commit5f3ac46907a6eca27be8c4b7bd8be69a009370c9 (patch)
treee4fb9e1f71685b2271ab362fea2136c8c92c1aa0
parenta134dd1559c4055e4f73085aa1980867ba7b4326 (diff)
downloadchocula-5f3ac46907a6eca27be8c4b7bd8be69a009370c9.tar.gz
chocula-5f3ac46907a6eca27be8c4b7bd8be69a009370c9.zip
handle 'ttp://' URL prefix corner case
-rwxr-xr-xchocula.py2
1 files changed, 2 insertions, 0 deletions
diff --git a/chocula.py b/chocula.py
index 3d77fe4..0125cb9 100755
--- a/chocula.py
+++ b/chocula.py
@@ -359,6 +359,8 @@ def parse_url(url):
return None
if url.startswith('www.'):
url = "http://" + url
+ if url.startswith('ttp://') or url.startswith('ttps://'):
+ url = "h" + url
url.replace('Http://', 'http://')
url = str(urlcanon.semantic_precise(url))