Skip to content

Commit 206d295

Browse files
committed
Fix page traversal links in prod
1 parent 65e27df commit 206d295

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

docs/src/helpers/navigation.js

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -308,10 +308,10 @@ export const getSidebarMenu = async ({ url, topbarSection }) => {
308308
};
309309

310310
/* Adds links for prev/next page used at bottom of guide pages */
311-
export const getPageTraversalLinks = async ({ url }) => {
311+
export const getPageTraversalLinks = async ({ url = '' }) => {
312+
url = url.replace(/\/$/, '');
312313
const menu = await await getFlattenedSidebarMenu({ url });
313314
const currentIndex = findIndex(menu, item => item.url == url);
314-
315315
let next;
316316
let previous;
317317
if (currentIndex >= 0) {

0 commit comments

Comments
 (0)