You are here

public function Notifications_Taxonomy_Term_Multiple_Subscription::get_name in Notifications 7

Get proper name

File

notifications_tags/notifications_tags.inc, line 264
Drupal Notifications Framework - Default class file

Class

Notifications_Taxonomy_Term_Multiple_Subscription
Subscription to simple taxonomy term

Code

public function get_name() {
  if (isset($this->name)) {
    return $this->name;
  }
  elseif ($terms = $this
    ->get_fields()) {
    foreach ($terms as $term_field) {
      $names[] = $term_field
        ->get_name();
    }
    return t('Content tagged with @terms', array(
      '@terms' => implode(', ', $names),
    ));
  }
  else {
    parent::get_name();
  }
}