logic for watching for filesystem changes moved to a separate class