Commit 5390722a authored by Jonas Götze's avatar Jonas Götze
Browse files

[BUGFIX] prevent error if record can not be found

parent 1fd7a0d8
......@@ -99,12 +99,14 @@ class T3oSaveToDatabaseFinisher extends \TYPO3\CMS\Form\Domain\Finishers\SaveToD
'insertedUids.' . $optionKey,
);
$record = BackendUtility::getRecord($this->options['table'], $recordUid);
$slug = $slugHelper->generate($record, $record['pid']);
$this->databaseConnection->update(
$this->options['table'],
[$slugFieldName => $slug],
['uid' => $recordUid]
);
if ($record) {
$slug = $slugHelper->generate($record, $record['pid']);
$this->databaseConnection->update(
$this->options['table'],
[$slugFieldName => $slug],
['uid' => $recordUid]
);
}
}
}
}
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment