Ignore 'parent directory' links

This commit is contained in:
Simon 2018-06-19 10:36:09 -04:00
parent 8f311e52ee
commit 8486555426

View File

@ -177,7 +177,7 @@ class HttpDirectory(RemoteDirectory):
@staticmethod
def _should_ignore(base_url, link: Anchor):
if link.text == "../" or link.href.endswith(HttpDirectory.BLACK_LIST):
if link.text == "../" or link.href == "../" or link.href.endswith(HttpDirectory.BLACK_LIST):
return True
# Ignore external links