Merge pull request #1936 from YannikFirre/patch-1
Add null check when setComplexValue is not found
This commit is contained in:
commit
8922632ead
|
|
@ -278,6 +278,11 @@ class TemplateProcessor
|
||||||
$elementWriter->write();
|
$elementWriter->write();
|
||||||
|
|
||||||
$where = $this->findContainingXmlBlockForMacro($search, 'w:r');
|
$where = $this->findContainingXmlBlockForMacro($search, 'w:r');
|
||||||
|
|
||||||
|
if ($where === false) {
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
|
||||||
$block = $this->getSlice($where['start'], $where['end']);
|
$block = $this->getSlice($where['start'], $where['end']);
|
||||||
$textParts = $this->splitTextIntoTexts($block);
|
$textParts = $this->splitTextIntoTexts($block);
|
||||||
$this->replaceXmlBlock($search, $textParts, 'w:r');
|
$this->replaceXmlBlock($search, $textParts, 'w:r');
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue