fix archive_org header rename

This commit is contained in:
Nick Sweeting 2020-07-22 01:46:38 -04:00
parent 25e0cba0cc
commit 0965031d8f
2 changed files with 7 additions and 8 deletions

View file

@ -106,7 +106,7 @@ def parse_archive_dot_org_response(response: bytes) -> Tuple[List[str], List[str
headers[name.lower().strip()].append(val.strip())
# Get successful archive url in "content-location" header or any errors
content_location = headers['content-location']
content_location = headers.get('content-location', headers['location'])
errors = headers['x-archive-wayback-runtime-error']
return content_location, errors