A little code cleanup for CSV uploads