diff --git a/importexport/inc/class.importexport_import_ui.inc.php b/importexport/inc/class.importexport_import_ui.inc.php index 9344e3335f..4c8fed1414 100644 --- a/importexport/inc/class.importexport_import_ui.inc.php +++ b/importexport/inc/class.importexport_import_ui.inc.php @@ -325,7 +325,7 @@ $data = translation::convert($data,$options['charset']); $ok = true; - if(count($data) != count($options['field_mapping']) && max(array_keys($data)) != max(array_keys($options['field_mapping']))) + if(count($data) != count($options['csv_fields']) && max(array_keys($data)) != max(array_keys($options['csv_fields']))) { $message[] = lang("Column mismatch. Expected %1 columns, your file has %2.", count($options['field_mapping']),