protected ContentEntityStorageBase::invokeFieldPostSave(ContentEntityInterface $entity, $update)
Invokes the post save method on the Field objects within an entity.
\Drupal\Core\Entity\ContentEntityInterface $entity: The entity object.
bool $update: Specifies whether the entity is being updated or created.
protected function invokeFieldPostSave(ContentEntityInterface $entity, $update) { // For each entity translation this returns an array of resave flags keyed // by field name, thus we merge them to obtain a list of fields to resave. $resave = []; foreach ($this->invokeFieldMethod('postSave', $entity, $update) as $translation_results) { $resave += array_filter($translation_results); } if ($resave) { $this->doSaveFieldItems($entity, array_keys($resave)); } }
© 2001–2016 by the original authors
Licensed under the GNU General Public License, version 2 and later.
Drupal is a registered trademark of Dries Buytaert.
https://api.drupal.org/api/drupal/core!lib!Drupal!Core!Entity!ContentEntityStorageBase.php/function/ContentEntityStorageBase::invokeFieldPostSave/8.1.x