diff --git a/src/octoprint/server/views.py b/src/octoprint/server/views.py index 6140eb4c..0a825e2f 100644 --- a/src/octoprint/server/views.py +++ b/src/octoprint/server/views.py @@ -530,7 +530,7 @@ def _files_for_index(): def _compute_date(files): from datetime import datetime - timestamps = map(lambda path: os.stat(path).st_mtime, files) + timestamps = map(lambda path: os.stat(path).st_mtime, files) + [0] if files else [] max_timestamp = max(*timestamps) if timestamps else None if max_timestamp: # we set the micros to 0 since microseconds are not speced for HTTP