mirror of
https://github.com/Garmelon/PFERD.git
synced 2026-04-12 15:35:05 +02:00
Ignore 1970 dates as windows crashes when calling .timestamp()
This commit is contained in:
parent
e32c1f000f
commit
eb4de8ae0c
1 changed files with 2 additions and 1 deletions
|
|
@ -231,7 +231,8 @@ class OutputDirectory:
|
||||||
stat = local_path.stat()
|
stat = local_path.stat()
|
||||||
|
|
||||||
remote_newer = None
|
remote_newer = None
|
||||||
if mtime := heuristics.mtime:
|
if heuristics.mtime and heuristics.mtime.year > 1970:
|
||||||
|
mtime = heuristics.mtime
|
||||||
remote_newer = mtime.timestamp() > stat.st_mtime
|
remote_newer = mtime.timestamp() > stat.st_mtime
|
||||||
if remote_newer:
|
if remote_newer:
|
||||||
log.explain("Remote file seems to be newer")
|
log.explain("Remote file seems to be newer")
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue