csv import small refactor