Skip to content

Commit

Permalink
cleanup unused pages router method
Browse files Browse the repository at this point in the history
  • Loading branch information
ztanner committed Jul 12, 2024
1 parent df1a427 commit e4c5085
Showing 1 changed file with 5 additions and 12 deletions.
17 changes: 5 additions & 12 deletions packages/next/src/shared/lib/router/router.ts
Original file line number Diff line number Diff line change
Expand Up @@ -1989,6 +1989,11 @@ export default class Router implements BaseRouter {
isBackground,
}

console.log(
'sho7uld we fetch here',
{ isQueryUpdating, isMiddlewareRewrite, route },
isQueryUpdating && !isMiddlewareRewrite
)
let data:
| WithMiddlewareEffectsOutput
| (Pick<WithMiddlewareEffectsOutput, 'json'> &
Expand Down Expand Up @@ -2501,18 +2506,6 @@ export default class Router implements BaseRouter {
})
}

_getFlightData(dataHref: string) {
// Do not cache RSC flight response since it's not a static resource
return fetchNextData({
dataHref,
isServerRender: true,
parseJSON: false,
inflightCache: this.sdc,
persistCache: false,
isPrefetch: false,
}).then(({ text }) => ({ data: text }))
}

getInitialProps(
Component: ComponentType,
ctx: NextPageContext
Expand Down

0 comments on commit e4c5085

Please sign in to comment.