Skip to content
Open
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
5 changes: 2 additions & 3 deletions src/lib/cache-tags.ts
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
import type * as Next from 'next'
import Router from 'next/router'
import { resolveHref } from 'next/dist/shared/lib/router/router'
import { resolveHref } from 'next/dist/client/resolve-href'

import { get } from './stack'
import type { CacheTagsRegistry } from './registry/type'
Expand Down Expand Up @@ -103,8 +103,7 @@ class CacheTags<R extends CacheTagsRegistry> {
if (!pathname) {
throw new Error('Could not resolve page pathname')
}

return resolveHref(Router, { pathname, query: ctx.params }, true)[1]
return resolveHref(Router, { href: pathname, query: ctx.params })[1]
}

/**
Expand Down
Loading