diff --git a/archivebox/util.py b/archivebox/util.py index 681218fe..265815ff 100644 --- a/archivebox/util.py +++ b/archivebox/util.py @@ -212,15 +212,19 @@ def download_url(url): return source_path -def fetch_page_title(url, default=None): +def fetch_page_title(url, default=True): """Attempt to guess a page's title by downloading the html""" - + if default is True: + default = url + try: html_content = urllib.request.urlopen(url).read().decode('utf-8') match = re.search('