function locale_update_7002

7.x locale.install locale_update_7002()

Updates URL language negotiation by adding the URL fallback detection method.

Related topics

File

drupal-7.x/modules/locale/locale.install, line 117
Install, update and uninstall functions for the locale module.

Code

function locale_update_7002() {
  // language.inc may not have been included during bootstrap if there is not
  // more than one language currently enabled.
  require_once DRUPAL_ROOT . '/includes/language.inc';
  $language_types_info = language_types_info();
  $info = $language_types_info[LANGUAGE_TYPE_URL];
  if (isset($info['fixed'])) {
    language_negotiation_set(LANGUAGE_TYPE_URL, array_flip($info['fixed']));
  }
}