diff --git a/addressfield_tokens.module b/addressfield_tokens.module index 83550ff..24eb1da 100644 --- a/addressfield_tokens.module +++ b/addressfield_tokens.module @@ -304,10 +304,12 @@ function _addressfield_tokens_country_abbr($country) { * abbreviations and the values are the full country names. */ function _addressfield_tokens_states($country) { + global $language; + $langcode = $language->language; $states = &drupal_static(__FUNCTION__); $country = drupal_strtoupper($country); if (!isset($states[$country])) { - $cache = cache_get('addressfield_tokens_states'); + $cache = cache_get('addressfield_tokens_states:' . $langcode); if ($cache) { $states = $cache->data; } @@ -321,7 +323,7 @@ function _addressfield_tokens_states($country) { else { $states[$country] = array(); } - cache_set('addressfield_tokens_states', $states); + cache_set('addressfield_tokens_states:' . $langcode, $states); } return $states[$country]; }