Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
adjust relativePathStart logic
Corrects `relativePath` and `editPath` for GitHub queries
  • Loading branch information
wackerow committed Dec 14, 2021
commit 39722f5a404600768cedf4586a7c3531b604dadf
2 changes: 1 addition & 1 deletion gatsby-node.js
Original file line number Diff line number Diff line change
Expand Up @@ -179,7 +179,7 @@ exports.onCreateNode = async ({ node, getNode, actions }) => {
}

const absolutePath = node.fileAbsolutePath
const relativePathStart = absolutePath.indexOf("src/")
const relativePathStart = absolutePath.lastIndexOf("src/")
const relativePath = absolutePath.substring(relativePathStart)

// Boolean if page is outdated (most translated files are)
Expand Down