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

Fix wrong sitemap for alternate url #828

Merged
merged 1 commit into from
Jul 4, 2018
Merged

Conversation

endiliey
Copy link
Contributor

@endiliey endiliey commented Jul 3, 2018

Motivation

#765 missed the implementation for langUrl, so the sitemap url is wrong for alternate url
826

In addition, I refactored few places to use getPath function instead of using replace(/\.html$/, '') just for reusability. Added tests also for regression on the function

Have you read the Contributing Guidelines on pull requests?

Yes

Test Plan

Test all url seems to work locally

And sitemap is now correct on alternate
cor

Related PRs

#765

@endiliey endiliey requested a review from yangshun July 3, 2018 18:23
@facebook-github-bot facebook-github-bot added the CLA Signed Signed Facebook CLA label Jul 3, 2018
@docusaurus-bot
Copy link
Contributor

Deploy preview for docusaurus-preview ready!

Built with commit d053f51

https://deploy-preview-828--docusaurus-preview.netlify.com

Copy link
Contributor

@yangshun yangshun left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Much needed refactoring. Thanks for adding the tests as well! 👍

@yangshun yangshun merged commit 3566483 into facebook:master Jul 4, 2018
@endiliey endiliey deleted the sitemap branch July 4, 2018 18:13
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
CLA Signed Signed Facebook CLA
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants