Skip to content

Commit ae11735

Browse files
jakebaileyCopilot
andauthored
Apply suggestion from @Copilot
Co-authored-by: Copilot <[email protected]>
1 parent 4a047d6 commit ae11735

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

internal/compiler/fileloader.go

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -266,10 +266,10 @@ func (p *fileLoader) addRootTask(fileName string, libFile *LibFile, includeReaso
266266
libFile: libFile,
267267
includeReason: includeReason,
268268
})
269-
} else if tspath.HasExtension(fileName) {
269+
} else if tspath.HasExtension(absPath) {
270270
// File has an extension but it's not in the supported extensions list
271271
// Check if it's a JavaScript file and report the appropriate diagnostic
272-
canonicalFileName := tspath.GetCanonicalFileName(fileName, p.opts.Host.FS().UseCaseSensitiveFileNames())
272+
canonicalFileName := tspath.GetCanonicalFileName(absPath, p.opts.Host.FS().UseCaseSensitiveFileNames())
273273
if tspath.HasJSFileExtension(canonicalFileName) {
274274
p.includeProcessor.addProcessingDiagnostic(&processingDiagnostic{
275275
kind: processingDiagnosticKindExplainingFileInclude,

0 commit comments

Comments
 (0)