Skip to content
This repository has been archived by the owner on Apr 6, 2023. It is now read-only.

Commit

Permalink
fix(vite): pass ssr condition to getModuleByUrl (#7260)
Browse files Browse the repository at this point in the history
  • Loading branch information
danielroe authored Sep 5, 2022
1 parent 497972b commit d115b01
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion packages/vite/src/utils/warmup.ts
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ export async function warmupViteServer (
} catch (e) {
logger.debug('Warmup for %s failed with: %s', url, e)
}
const mod = await server.moduleGraph.getModuleByUrl(url)
const mod = await server.moduleGraph.getModuleByUrl(url, isServer)
const deps = Array.from(mod?.importedModules || [])
await Promise.all(deps.map(m => warmup(m.url.replace('/@id/__x00__', '\0'))))
}
Expand Down

0 comments on commit d115b01

Please sign in to comment.