mikemaccana / outdated-browser-rework

Detects outdated browsers and advises users to upgrade to a new version. Handles mobile devices!
MIT License
226 stars 63 forks source link

fix wrong CJK language codes #108

Closed ZigZagT closed 4 years ago

ZigZagT commented 4 years ago

according to specs:

https://developer.mozilla.org/en-US/docs/Web/API/NavigatorLanguage/language

https://tools.ietf.org/rfc/bcp/bcp47.txt

  1. Two-character primary language subtags were defined in the IANA registry according to the assignments found in the standard "ISO 639-1:2002, Codes for the representation of names of languages -- Part 1: Alpha-2 code" [ISO639-1], or using assignments subsequently made by the ISO 639-1 registration authority (RA) or governing standardization bodies.

where ISO 639-1 uses ja, zh and ko for CJK languages.

Tested on latest Chrome and Firefox