gatsby-core-theme 44.0.2 → 44.0.3

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/CHANGELOG.md CHANGED
@@ -1,3 +1,11 @@
1
+ ## [44.0.3](https://gitlab.com/g2m-gentoo/team-floyd/themes/gatsby-themes/compare/v44.0.2...v44.0.3) (2025-03-14)
2
+
3
+
4
+ ### Bug Fixes
5
+
6
+ * redirect links ([7656319](https://gitlab.com/g2m-gentoo/team-floyd/themes/gatsby-themes/commit/76563195d77ba19023efb5411fd511fcc9218d7e))
7
+ * redirects with trailing slash ([1ece82d](https://gitlab.com/g2m-gentoo/team-floyd/themes/gatsby-themes/commit/1ece82dbe8b916d7f8c78cc4aa0e5d745dfbf6d5))
8
+
1
9
  ## [44.0.2](https://gitlab.com/g2m-gentoo/team-floyd/themes/gatsby-themes/compare/v44.0.1...v44.0.2) (2025-03-14)
2
10
 
3
11
 
package/gatsby-node.mjs CHANGED
@@ -261,8 +261,8 @@ export const createPages = async (
261
261
  const redirectName =
262
262
  parseInt(value.type) === 301 ? "permanent" : "redirect";
263
263
 
264
- const to = normalizedTo !== "/" ? (process.env.TRAILING_SLASH === 'true' ? `${normalizedTo}/` : normalizedTo) : normalizedTo;
265
- console.log(to);
264
+ const toSanitized = normalizedTo !== "/" ? normalizedTo.replace(/\/$/, '') : normalizedTo;
265
+ const to = toSanitized !== "/" ? (process.env.TRAILING_SLASH === 'true' ? `${toSanitized}/` : toSanitized) : toSanitized;
266
266
 
267
267
  stream.write(
268
268
  `rewrite (?i)^${normalizedFrom}/?$ ${to} ${redirectName}; \n`
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "gatsby-core-theme",
3
- "version": "44.0.2",
3
+ "version": "44.0.3",
4
4
  "description": "Gatsby Theme NPM Package",
5
5
  "author": "",
6
6
  "license": "ISC",