addLocale(site, newLocaleList, preferredLocale);
}
// retrieve the browser locales
for (@SuppressWarnings("unchecked")
Iterator<Locale> browserLocales = new EnumerationIterator(request.getLocales()); browserLocales
.hasNext();) {
final Locale curLocale = browserLocales.next();
if (siteLanguages.contains(curLocale)) {
addLocale(site, newLocaleList, curLocale);
} else if (!StringUtils.isEmpty(curLocale.getCountry())) {
final Locale langOnlyLocale = new Locale(curLocale.getLanguage());
if (siteLanguages.contains(langOnlyLocale)) {