Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Make compatible_language_from follow the RFC 2616 selection algorithm
We need to look for the longest matching prefix rather than just the first language with the same basic language code, otherwise if we have both zh-CN and zh-TW available then we may select the wrong one as we will return he first one we see that starts with zh even if the user had said they preferred a specific variant.
- Loading branch information