You are here

public function EntityHelper::getBundleLabel in Simple XML sitemap 8.3

Parameters

string $entity_type_id:

string $bundle_name:

Return value

mixed

File

src/EntityHelper.php, line 62

Class

EntityHelper
Helper class for working with entities.

Namespace

Drupal\simple_sitemap

Code

public function getBundleLabel($entity_type_id, $bundle_name) {
  $entity_info = $this
    ->getBundleInfo($entity_type_id);
  return isset($entity_info[$bundle_name]['label']) ? $entity_info[$bundle_name]['label'] : $bundle_name;

  // Menu fix.
}