Skip to content
This repository has been archived by the owner on Sep 22, 2023. It is now read-only.

[BUG] Pretty URLs might not respond #49

Closed
Trinityyi opened this issue Jan 8, 2020 · 1 comment · Fixed by #50
Closed

[BUG] Pretty URLs might not respond #49

Trinityyi opened this issue Jan 8, 2020 · 1 comment · Fixed by #50
Assignees
Labels
backend Related to backend code bug Something isn't working maintenance Maintenance task SEO Related to search engine optimization

Comments

@Trinityyi
Copy link
Contributor

Bug description

Sometimes, pretty URLs (without trailing /) might not respond correctly.

Steps to reproduce

Expected behavior

Should respond with the correct page

Screenshots

image

Environment

  • Windows 10
  • Chrome (Version 76)
  • Behind Enterprise Firewall
@Chalarangelo Chalarangelo added backend Related to backend code bug Something isn't working maintenance Maintenance task not-stale SEO Related to search engine optimization labels Jan 8, 2020
@Chalarangelo Chalarangelo self-assigned this Jan 8, 2020
@Chalarangelo Chalarangelo added this to To do in 2020 via automation Jan 8, 2020
@Chalarangelo Chalarangelo added this to the 2020 Sprint #1 milestone Jan 8, 2020
@Trinityyi Trinityyi changed the title [Bug] Pretty URLs might not respond [BUG] Pretty URLs might not respond Jan 8, 2020
@Chalarangelo
Copy link
Owner

Chalarangelo commented Jan 8, 2020

Thanks for the heads up, @Trinityyi!

I cannot reproduce easily, but it seems that using ugly URLs (with trailing /) when linking should fix this. Netlify and Gatsby will redirect the ugly URL to the pretty one anyways, so that's pretty much an easy fix. Added to the current sprint, shouldn't be too hard to fix over the weekend.

Possible solution

Add a check for internal links not having a trailing /, account for URL parameters, add the trailing slash before sending the link to the Link component and it should be good to go. Doesn't break anything, requires a couple of extra tests.

Chalarangelo added a commit that referenced this issue Jan 8, 2020
Resolves #49
Handle some edge-cases of pretty URLs
@Chalarangelo Chalarangelo moved this from To do to In progress in 2020 Jan 8, 2020
2020 automation moved this from In progress to Done Jan 10, 2020
Chalarangelo added a commit that referenced this issue Jan 13, 2020
Resolves #49
Handle some edge-cases of pretty URLs
@lock lock bot locked as resolved and limited conversation to collaborators Mar 10, 2020
@Chalarangelo Chalarangelo removed this from Done in 2020 Oct 23, 2023
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
backend Related to backend code bug Something isn't working maintenance Maintenance task SEO Related to search engine optimization
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants