Получение программно текущей локали

Magento 1.x

Mage::app()->getLocale()->getLocaleCode()

Magento 2

/** @return string */
function rm_locale() {
	/** @var \Magento\Framework\ObjectManagerInterface $om */
	$om = \Magento\Framework\App\ObjectManager::getInstance();
	/** @var \Magento\Framework\Locale\Resolver $resolver */
	$resolver = $om->get('Magento\Framework\Locale\Resolver');
	return $resolver->getLocale();
}