Skip to content

Commit

Permalink
chore: cleanup
Browse files Browse the repository at this point in the history
  • Loading branch information
sheremet-va committed Apr 16, 2024
1 parent 7a740a1 commit 43d8704
Showing 1 changed file with 2 additions and 3 deletions.
5 changes: 2 additions & 3 deletions packages/vite/src/module-runner/runner.ts
Original file line number Diff line number Diff line change
Expand Up @@ -294,11 +294,10 @@ export class ModuleRunner {
const callstack = [..._callstack, moduleId]

const request = async (dep: string, metadata?: SSRImportMetadata) => {
const importer =
(mod.meta && 'file' in mod.meta && mod.meta.file) || moduleId
const importer = ('file' in fetchResult && fetchResult.file) || moduleId
const fetchedModule = await this.cachedModule(dep, importer)
const resolvedId = fetchedModule.meta!.id
const depMod = this.moduleCache.getByModuleId(fetchedModule.id)
const depMod = this.moduleCache.getByModuleId(resolvedId)
depMod.importers!.add(moduleId)
mod.imports!.add(resolvedId)

Expand Down

0 comments on commit 43d8704

Please sign in to comment.