Skip to content

Commit

Permalink
chore: broken test
Browse files Browse the repository at this point in the history
  • Loading branch information
harlan-zw committed Aug 19, 2023
1 parent 5029be1 commit 005b767
Showing 1 changed file with 1 addition and 3 deletions.
4 changes: 1 addition & 3 deletions src/utils.ts
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ export interface NuxtPagesToSitemapEntriesOptions {
}

export function convertNuxtPagesToSitemapEntries(pages: NuxtPage[], config: NuxtPagesToSitemapEntriesOptions) {
const routeNameSeperator = config.routeNameSeperator || '__'
const routeNameSeperator = config.routeNameSeperator || '___'
const flattenedPages = pages
.map((page) => {
return page.children?.length
Expand Down Expand Up @@ -46,8 +46,6 @@ export function convertNuxtPagesToSitemapEntries(pages: NuxtPage[], config: Nuxt
pagesWithMeta.reduce((acc: Record<string, any>, entry) => {
if (entry.page.name?.includes(routeNameSeperator)) {
let [name, locale] = entry.page.name.split(routeNameSeperator)
if (locale)
locale = locale.slice(1)
if (!acc[name])
acc[name] = []
acc[name].push({ ...entry, locale })
Expand Down

0 comments on commit 005b767

Please sign in to comment.