Fix an InvalidOperationException in the import wizard.