Better error messages when duplicate file names are added