Using 'zz' breaks strong-globalize
zmau3r opened this issue · 1 comments
zmau3r commented
Repro:
sg_defect.tar.gz
https://asciinema.org/a/tJEmYQYe7T1ZVaohtIt6j2EZ7
Strong-globalize instance breaks after setting 'zz' language.
Any language used after 'zz' will not work and throw an error.
TypeError: Cannot read property '0' of undefined
at coreRemoveLikelySubtags (/Users/zjm/node_modules/strong-globalize/deps/cldrjs/dist/cldr.js:187:28)
at /Users/zjm/node_modules/strong-globalize/deps/cldrjs/dist/cldr.js:302:17
at Array.forEach (<anonymous>)
at arrayForEach (/Users/zjm/node_modules/strong-globalize/deps/cldrjs/dist/cldr.js:274:17)
at bundleLookup (/Users/zjm/node_modules/strong-globalize/deps/cldrjs/dist/cldr.js:298:4)
at Cldr.init (/Users/zjm/node_modules/strong-globalize/deps/cldrjs/dist/cldr.js:614:12)
at Cldr.init (/Users/zjm/node_modules/strong-globalize/deps/cldrjs/dist/cldr/event.js:554:13)
at Cldr.init (/Users/zjm/node_modules/strong-globalize/deps/cldrjs/dist/cldr/supplemental.js:92:13)
at new Cldr (/Users/zjm/node_modules/strong-globalize/deps/cldrjs/dist/cldr.js:547:8)
at alwaysCldr (/Users/zjm/node_modules/strong-globalize/deps/globalize/dist/globalize.js:307:55)