Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[l10n] Treat language as case-insensitive #5692

Merged
merged 1 commit into from
Mar 10, 2015

Conversation

Rob--W
Copy link
Member

@Rob--W Rob--W commented Feb 2, 2015

RFC 4646 specifies that language tags should be treated case-insensitively, so the previous work-around to #4335 is insufficient: The patch should not be added to compatibility.js, but become a part of the l10n library.

See "Case-insensitive language comparisons per RFC 4646" @ fabi1cazenave/webL10n#51

(I've created this patch because I've noticed that navigator.language is lowercase in Chrome 40: https://code.google.com/p/chromium/issues/detail?id=454331)

See "Case-insensitive language comparisons per RFC 4646"
fabi1cazenave/webL10n#51

Removed the "patch" in compatibility.js and fixed the bug in webL10n,
because the logic belongs to webL10n instead of PDF.js.
The immediate motivation for this patch is that Chrome 40 converts
navigator.language to lower case: https://crbug.com/454331
@timvandermeij
Copy link
Contributor

@yurydelendik This patch has been merged upstream in the meantime. Could you review this so we can merge it here too?

yurydelendik added a commit that referenced this pull request Mar 10, 2015
[l10n] Treat language as case-insensitive
@yurydelendik yurydelendik merged commit da258f8 into mozilla:master Mar 10, 2015
@yurydelendik
Copy link
Contributor

Thank you for the patch!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants