if ($sections =
$this->
getEntitySections($entity)) { if ($this->
originalEntityUsesDefaultStorage($entity)) { // This is a new override from a default and the blocks need to be
// duplicated.
$duplicate_blocks = TRUE;
} // Since multiple parent entity revisions may reference common block
// revisions, when a block is modified, it must always result in the
// creation of a new block revision.
$new_revision =
$entity instanceof RevisionableInterface;
foreach ($this->
getInlineBlockComponents($sections) as $component) { $this->
saveInlineBlockComponent($entity,
$component,
$new_revision,
$duplicate_blocks);
} } $this->
removeUnusedForEntityOnSave($entity);
} /**
* Gets a block ID for an inline block plugin.
*
* @param \Drupal\layout_builder\Plugin\Block\InlineBlock $block_plugin
* The inline block plugin.
*
* @return int
* The block content ID or null none available.
*/