You are here

protected function SqlContentEntityStorage::doLoadRevisionFieldItems in Drupal 8

Actually loads revision field item values from the storage.

Parameters

int|string $revision_id: The revision identifier.

Return value

\Drupal\Core\Entity\EntityInterface|null The specified entity revision or NULL if not found.

Overrides ContentEntityStorageBase::doLoadRevisionFieldItems

Deprecated

in drupal:8.5.0 and is removed from drupal:9.0.0. \Drupal\Core\Entity\ContentEntityStorageBase::doLoadMultipleRevisionsFieldItems() should be implemented instead.

See also

https://www.drupal.org/node/2924915

File

core/lib/Drupal/Core/Entity/Sql/SqlContentEntityStorage.php, line 634

Class

SqlContentEntityStorage
A content entity database storage implementation.

Namespace

Drupal\Core\Entity\Sql

Code

protected function doLoadRevisionFieldItems($revision_id) {
  @trigger_error('"\\Drupal\\Core\\Entity\\ContentEntityStorageBase::doLoadRevisionFieldItems()" is deprecated in Drupal 8.5.x and will be removed before Drupal 9.0.0. "\\Drupal\\Core\\Entity\\ContentEntityStorageBase::doLoadMultipleRevisionsFieldItems()" should be implemented instead. See https://www.drupal.org/node/2924915.', E_USER_DEPRECATED);
  $revisions = $this
    ->doLoadMultipleRevisionsFieldItems([
    $revision_id,
  ]);
  return !empty($revisions) ? reset($revisions) : NULL;
}