Code Duplication    Length = 3-3 lines in 2 locations

Core/MigrationService.php 2 locations

@@ 263-265 (lines=3) @@
260
            $migrationDefinition = $this->parseMigrationDefinition($migrationDefinition);
261
        }
262
263
        if ($migrationDefinition->status == MigrationDefinition::STATUS_INVALID) {
264
            throw new \Exception("Can not execute " . $this->getEntityName($migrationDefinition). " '{$migrationDefinition->name}': {$migrationDefinition->parsingError}");
265
        }
266
267
        /// @todo add support for setting in $migrationContext a userContentType ?
268
        $migrationContext = $this->migrationContextFromParameters($defaultLanguageCode, $adminLogin);
@@ 445-447 (lines=3) @@
442
        $migrationDefinition = reset($defs);
443
444
        $migrationDefinition = $this->parseMigrationDefinition($migrationDefinition);
445
        if ($migrationDefinition->status == MigrationDefinition::STATUS_INVALID) {
446
            throw new \Exception("Can not resume ".$this->getEntityName($migration)." '{$migration->name}': {$migrationDefinition->parsingError}");
447
        }
448
449
        // restore context
450
        $this->contextHandler->restoreCurrentContext($migration->name);