Cleanup and move-sent execution logging

This commit is contained in:
Profitroll 2022-08-09 11:51:57 +02:00
parent a4904235af
commit f790cafbef
1 changed files with 2 additions and 0 deletions

View File

@ -21,6 +21,7 @@ if "--move-sent" in sys.argv:
logWrite(f"File '{entry}' is already moved or does not exist")
except Exception as exp:
logWrite(f"Could not move sent file '{entry}' to '{configGet('sent', 'locations')}' due to {exp}")
logWrite(f"Moved all sent files to the sent folder")
if "--cleanup" in sys.argv:
if "--confirm" in sys.argv:
@ -36,6 +37,7 @@ if "--cleanup" in sys.argv:
pass
except Exception as exp:
logWrite(f"Could not remove '{entry}' due to {exp}")
logWrite(f"Performed cleanup of the sent files")
else:
logWrite(f"Requested cleanup of sent files but not authorized. Please pass '--confirm' to perform that")