mirror of
https://github.com/unicode-org/icu.git
synced 2025-04-21 12:40:02 +00:00
ICU-2678 revert some changes, to make the behaviour analogous to ICU4C
X-SVN-Rev: 12279
This commit is contained in:
parent
18ca69ab9a
commit
a80c79d030
1 changed files with 2 additions and 4 deletions
|
@ -334,11 +334,9 @@ public final class UScript {
|
|||
*/
|
||||
private static int[] findCodeFromLocale(Locale locale) {
|
||||
ResourceBundle rb = ICULocaleData.getLocaleElements(locale);
|
||||
if (rb==null) {
|
||||
throw new MissingResourceException("Could not find data for {0} {1}", "com.ibm.icu.impl.dataLocaleElements", locale.toString());
|
||||
}
|
||||
|
||||
// if rb is not a strict fallback of the requested locale, return null
|
||||
if(!LocaleUtility.isFallbackOf(rb.getLocale(), locale)){
|
||||
if(rb==null || !LocaleUtility.isFallbackOf(rb.getLocale(), locale)){
|
||||
return null;
|
||||
}
|
||||
String[] scripts = rb.getStringArray("LocaleScript");
|
||||
|
|
Loading…
Add table
Reference in a new issue