Scrub watch snapshot fixes

This commit is contained in:
dgtlmoon
2022-01-15 23:18:04 +01:00
committed by GitHub
parent a896493797
commit b7ca10ebac
2 changed files with 6 additions and 6 deletions

View File

@@ -304,7 +304,7 @@ class ChangeDetectionStore:
if not limit_timestamp: if not limit_timestamp:
self.data['watching'][uuid]['last_checked'] = 0 self.data['watching'][uuid]['last_checked'] = 0
self.data['watching'][uuid]['last_changed'] = 0 self.data['watching'][uuid]['last_changed'] = 0
self.data['watching'][uuid]['previous_md5'] = 0 self.data['watching'][uuid]['previous_md5'] = ""
for timestamp in del_timestamps: for timestamp in del_timestamps:
@@ -323,7 +323,7 @@ class ChangeDetectionStore:
content = fp.read() content = fp.read()
self.data['watching'][uuid]['previous_md5'] = hashlib.md5(content).hexdigest() self.data['watching'][uuid]['previous_md5'] = hashlib.md5(content).hexdigest()
except (FileNotFoundError, IOError): except (FileNotFoundError, IOError):
self.data['watching'][uuid]['previous_md5'] = False self.data['watching'][uuid]['previous_md5'] = ""
pass pass
self.needs_write = True self.needs_write = True