public function EntityFormController::isDefaultFormLangcode

Implements EntityFormControllerInterface::isDefaultFormLangcode().

Overrides EntityFormControllerInterface::isDefaultFormLangcode

1 call to EntityFormController::isDefaultFormLangcode()
EntityFormController::submitEntityLanguage in drupal/core/lib/Drupal/Core/Entity/EntityFormController.php
Handle possible entity language changes.

File

drupal/core/lib/Drupal/Core/Entity/EntityFormController.php, line 246
Definition of Drupal\Core\Entity\EntityFormController.

Class

EntityFormController
Base class for entity form controllers.

Namespace

Drupal\Core\Entity

Code

public function isDefaultFormLangcode($form_state) {
  return $this
    ->getFormLangcode($form_state) == $this
    ->getEntity($form_state)
    ->language()->langcode;
}