MT-85: The same validation has been added to the keep uid process.
This commit is contained in:
@@ -182,16 +182,13 @@ class GranularImporter
|
||||
* @return bool
|
||||
* @throws \Exception
|
||||
*/
|
||||
public function validateImportData($objectList, $generateUid = false)
|
||||
public function validateImportData($objectList)
|
||||
{
|
||||
try {
|
||||
|
||||
if ($generateUid) {
|
||||
if (count($objectList) !== count($this->exportObjects->getObjectsList())) {
|
||||
$exception = new ImportException();
|
||||
$exception->setNameException(\G::LoadTranslation('ID_PROCESS_DEFINITION_INCOMPLETE'));
|
||||
throw($exception);
|
||||
}
|
||||
if (count($objectList) !== count($this->exportObjects->getObjectsList())) {
|
||||
$exception = new ImportException();
|
||||
$exception->setNameException(\G::LoadTranslation('ID_PROCESS_DEFINITION_INCOMPLETE'));
|
||||
throw($exception);
|
||||
}
|
||||
return true;
|
||||
} catch (\Exception $e) {
|
||||
|
||||
Reference in New Issue
Block a user