From eb829546b60b0e1803bd32dd84dcb6ef3be4d94a Mon Sep 17 00:00:00 2001 From: Kevin Miller Date: Mon, 4 Jan 2021 11:05:46 -0800 Subject: [PATCH] chore: Update generated redirects to permanent. #1671 --- gatsby-node.js | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/gatsby-node.js b/gatsby-node.js index 2bd845294..a347dcd63 100644 --- a/gatsby-node.js +++ b/gatsby-node.js @@ -115,6 +115,7 @@ exports.createPages = async ({ graphql, actions }) => { createRedirect({ fromPath: `/document/download/${node.slug}`, toPath: node.document.file.url, + isPermanent: true, }) }) @@ -122,6 +123,7 @@ exports.createPages = async ({ graphql, actions }) => { createRedirect({ fromPath: from, toPath: redirectTo, + isPermanent: true, }) }) @@ -194,6 +196,7 @@ exports.createPages = async ({ graphql, actions }) => { createRedirect({ fromPath: `/data/state/${slug}/screenshots`, toPath: `https://screenshots.covidtracking.com/${slug}`, + isPermanent: true, }) }) @@ -230,6 +233,7 @@ exports.createPages = async ({ graphql, actions }) => { createRedirect({ fromPath: shortPath, toPath: node.overrideBlogPath, + isPermanent: true, }) } else { createPage({ @@ -241,6 +245,7 @@ exports.createPages = async ({ graphql, actions }) => { createRedirect({ fromPath: shortPath, toPath: longPath, + isPermanent: true, }) } })