UPDATE: Print error message if directory parameter is missing.