Refactor code to implement MultiImport