Skip to content

Commit

Permalink
Use mtime from files.xml if no Last-Modified header is available
Browse files Browse the repository at this point in the history
  • Loading branch information
jake authored and jake committed May 7, 2024
1 parent d8f2cc3 commit 903a833
Show file tree
Hide file tree
Showing 3 changed files with 9 additions and 2 deletions.
7 changes: 7 additions & 0 deletions HISTORY.rst
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,13 @@
Release History
---------------

4.1.0 (?)
+++++++++

**Bugfixes**

- Use mtime from files.xml if no Last-Modified header is available (e.g. VTT files).

4.0.1 (2024-04-15)
++++++++++++++++++

Expand Down
2 changes: 1 addition & 1 deletion internetarchive/__version__.py
Original file line number Diff line number Diff line change
@@ -1 +1 @@
__version__ = '4.0.1'
__version__ = '4.1.0.dev1'
2 changes: 1 addition & 1 deletion internetarchive/files.py
Original file line number Diff line number Diff line change
Expand Up @@ -252,7 +252,7 @@ def download(# noqa: max-complexity=38
dt = parsedate_to_datetime(last_mod_header)
last_mod_mtime = dt.timestamp()
else:
last_mod_mtime = 0
last_mod_mtime = self.mtime

response.raise_for_status()

Expand Down

0 comments on commit 903a833

Please sign in to comment.