Skip to content

Commit

Permalink
Support URLs that end in SemVer ranges (gatsbyjs#3305)
Browse files Browse the repository at this point in the history
  • Loading branch information
danoc authored and jastack committed Jan 24, 2018
1 parent 3ad469b commit 40df85e
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion packages/gatsby/src/commands/develop.js
Original file line number Diff line number Diff line change
Expand Up @@ -176,7 +176,7 @@ async function startServer(program) {
// Render an HTML page and serve it.
app.use((req, res, next) => {
const parsedPath = parsePath(req.path)
if (parsedPath.extname === `` || parsedPath.extname.startsWith(`.html`)) {
if (parsedPath.extname === `` || parsedPath.extname.startsWith(`.html`) || parsedPath.path.endsWith(`/`)) {
res.sendFile(directoryPath(`public/index.html`), err => {
if (err) {
res.status(500).end()
Expand Down

0 comments on commit 40df85e

Please sign in to comment.