1
0
Fork 0
mirror of synced 2024-06-29 19:50:26 +12:00

Merge pull request #1111 from TorstenDittmann/fix-migration-errors

fix(migration): prevent throwing error when document is missing ID
This commit is contained in:
Eldad A. Fux 2021-04-29 13:38:29 +03:00 committed by GitHub
commit e09c80ccd2
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -87,7 +87,8 @@ abstract class Migration
$new = call_user_func($callback, $document);
if (empty($new->getId())) {
throw new Exception('Missing ID');
Console::warning('Skipped Document due to missing ID.');
return;
}
if (!$this->check_diff_multi($new->getArrayCopy(), $old)) {