You are here

public function AddressItem::getLocale in Address 8

File

src/Plugin/Field/FieldType/AddressItem.php, line 340

Class

AddressItem
Plugin implementation of the 'address' field type.

Namespace

Drupal\address\Plugin\Field\FieldType

Code

public function getLocale() {
  $langcode = $this->langcode;
  if (!$langcode) {

    // If no langcode was stored, fallback to the field langcode.
    // Documented in initializeLangcode().
    $langcode = $this
      ->getLangcode();
  }
  return $langcode;
}