send the file type as an argument