You are here

public function CurrencyHelper::currentLanguage in Commerce Currency Resolver 8

Return current user language.

Return value

string Two letter language code.

Overrides CurrencyHelperInterface::currentLanguage

File

src/CurrencyHelper.php, line 145

Class

CurrencyHelper
Helper for various parts of the module.

Namespace

Drupal\commerce_currency_resolver

Code

public function currentLanguage() {
  return $this->languageManager
    ->getCurrentLanguage()
    ->getId();
}