Close the dialog after everything has been imported