1
Fork 0
mirror of https://github.com/RGBCube/serenity synced 2025-07-27 13:57:35 +00:00

LibJS: Extend Intl.DisplayNames.of to support currency tags

This commit is contained in:
Timothy Flynn 2021-08-26 08:39:20 -04:00 committed by Linus Groh
parent 8b93d51212
commit 86b99fd9a6
2 changed files with 16 additions and 0 deletions

View file

@ -86,6 +86,7 @@ JS_DEFINE_NATIVE_FUNCTION(DisplayNamesPrototype::of)
result = Unicode::get_locale_script_mapping(display_names->locale(), code.as_string().string());
break;
case DisplayNames::Type::Currency:
result = Unicode::get_locale_currency_mapping(display_names->locale(), code.as_string().string());
break;
default:
VERIFY_NOT_REACHED();