minor cleanup of the CSV code