rxaviers / cldrjs

Simple CLDR traverser

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Locale attribute "minlanguageId" property is populated with wrong case (should be "minLanguageId")

CodeChief opened this issue · comments

You populate the locale attribute "minLanguageId" with an incorrect case for the "L" of Language, i.e. "minlanguageId". See line 617 of cldr.js version 0.4.4 (current release version in NuGet):

    // Set attributes
    this.attributes = attributes = {
        bundle: bundleLookup( Cldr, this, minLanguageId ),

        // Unicode Language Id
        minlanguageId: minLanguageId,    <-- ERROR!
        maxLanguageId: maxLanguageId.join( sep ),

Please update your package with the latest CLDR code, which does not have this issue (no problem when using the NPM packages).

I wanted to use your NuGet version together with my own minified JSON CLDR-Data modules on my older solutions, which works if I can read the "minLanguageId" (effectively the CLDR bundle name) from the specific culture I get in .NET. Can imagine this could cause other failures as it's a pretty key piece of information which effectively becomes "undefined" when the case is wrong (JavaScript addressing of JSON objects being case sensitive of course).

Fixed since the NuGet packages were updated.