Fixed monitoring with on_modified (Thanks JayZed!)

This commit is contained in:
McCloudS
2024-03-19 15:45:07 -06:00
committed by GitHub
parent d5a918dfb8
commit f2aa233e01

View File

@@ -616,7 +616,7 @@ def path_mapping(fullpath):
if monitor: if monitor:
# Define a handler class that will process new files # Define a handler class that will process new files
class NewFileHandler(FileSystemEventHandler): class NewFileHandler(FileSystemEventHandler):
def on_created(self, event): def on_modified(self, event):
# Only process if it's a file # Only process if it's a file
if not event.is_directory: if not event.is_directory:
file_path = event.src_path file_path = event.src_path