When I tried to load locales from application.yml to List<Locale>, Spring Framework's LocaleEditor is called to map it, but locales with scripts like zh-Hans or zh-Hant are not handled correctly because the locale is not loaded with the Locale.forLanguageTag method.
In method setAsText of LocaleEditor, the call to StringUtils.parseLocaleString should probably be replaced with StringUtils.parseLocale like it is in StringToLocaleConverter.
When I tried to load locales from
application.ymltoList<Locale>, Spring Framework'sLocaleEditoris called to map it, but locales with scripts likezh-Hansorzh-Hantare not handled correctly because the locale is not loaded with theLocale.forLanguageTagmethod.In method
setAsTextofLocaleEditor, the call toStringUtils.parseLocaleStringshould probably be replaced withStringUtils.parseLocalelike it is inStringToLocaleConverter.