codestyle

This commit is contained in:
jonaswinkler
2021-05-19 20:26:12 +02:00
parent f9f4d4c937
commit 80ba5b561f
2 changed files with 9 additions and 4 deletions

View File

@@ -334,7 +334,10 @@ class Consumer(LoggingMixin):
os.unlink(self.path)
# https://github.com/jonaswinkler/paperless-ng/discussions/1037
shadow_file = os.path.join(os.path.dirname(self.path), "._" + os.path.basename(self.path))
shadow_file = os.path.join(
os.path.dirname(self.path),
"._" + os.path.basename(self.path))
if os.path.isfile(shadow_file):
self.log("debug", "Deleting file {}".format(shadow_file))
os.unlink(shadow_file)