function normalizeLanguageCode(languageCode) {
  var languageCodePattern = /^([a-zA-Z]{2})-([a-zA-Z]{2})$/;
  var partsOfLanguageCode = languageCodePattern.exec(languageCode);

  if (partsOfLanguageCode) {
    return "".concat(partsOfLanguageCode[1].toLowerCase(), "-").concat(partsOfLanguageCode[2].toUpperCase());
  }

  return languageCode;
}
Normalize language code. It takes handled languageCode proposition and change it to proper languageCode.
For example, when it takes `eN-us` as parameter it return `en-US`

@param {String} languageCode Language code for specific language i.e. 'en-US', 'pt-BR', 'de-DE'.
@returns {String}