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

Feat add alias support for zh-cn and zh-tw #151

Merged
merged 1 commit into from Jan 13, 2020
Merged

Feat add alias support for zh-cn and zh-tw #151

merged 1 commit into from Jan 13, 2020

Conversation

@jannyHou
Copy link
Contributor

jannyHou commented Jan 9, 2020

support feature in #150

If a request.header has accept-language of zh-cn or zh-tw, strong-globalize should equivocate that to zh-Hans and zh-Hant respectively.

The change is applied to http(), setLanguage() and setDefaultLanguage.

@bajtos

This comment has been minimized.

Copy link
Member

bajtos commented Jan 10, 2020

The issue #150 is describing a problem when using g.http() function. Can you please add a test to verify the problem reported in that issue is solved by your changes?

@jannyHou jannyHou force-pushed the feat/alias branch 2 times, most recently from cf2db9d to cbf0694 Jan 13, 2020
@jannyHou jannyHou changed the title Feat/alias Feat add alias support for zh-cn and zh-tw Jan 13, 2020

/**
* If an language has alias name that SG supports, return the alias name.
* @param lang

This comment has been minimized.

Copy link
@raymondfeng

raymondfeng Jan 13, 2020

Member

Maybe add a ref to #150 and say we hard-code the known aliases for now.

@jannyHou jannyHou force-pushed the feat/alias branch from cbf0694 to e2d482f Jan 13, 2020
@jannyHou jannyHou merged commit d21fac9 into master Jan 13, 2020
6 checks passed
6 checks passed
Commit Linter commits are all properly formatted
Details
PR Linter PR is up to date
Details
clahub All contributors have signed the Contributor License Agreement.
Details
continuous-integration/travis-ci/pr The Travis CI build passed
Details
continuous-integration/travis-ci/push The Travis CI build passed
Details
security/snyk - package.json (StrongLoop) No manifest changes detected
@delete-merged-branch delete-merged-branch bot deleted the feat/alias branch Jan 13, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Linked issues

Successfully merging this pull request may close these issues.

None yet

3 participants
You can’t perform that action at this time.