You are here

public function BundleItemOrderItem::getPurchasedEntity in Commerce Product Bundle 8

Gets the purchased entity.

Return value

\Drupal\commerce\PurchasableEntityInterface|null The purchased entity, or NULL.

Overrides BundleItemOrderItemInterface::getPurchasedEntity

File

src/Entity/BundleItemOrderItem.php, line 74

Class

BundleItemOrderItem
Defines the Bundle Item Order Item entity.

Namespace

Drupal\commerce_product_bundle\Entity

Code

public function getPurchasedEntity() {
  return $this
    ->getTranslatedReferencedEntity('purchased_entity');
}