mirror of
https://github.com/microsoft/TypeScript.git
synced 2026-02-15 03:23:08 -06:00
Include fewer paths in exception
It's sufficient to append them to the log.
This commit is contained in:
parent
b24050aefd
commit
d9780cd7ba
@ -1158,7 +1158,7 @@ namespace ts {
|
||||
function getValidSourceFile(fileName: string): SourceFile {
|
||||
const sourceFile = program.getSourceFile(fileName);
|
||||
if (!sourceFile) {
|
||||
throw new Error(`Could not find sourceFile: '${fileName}' in ${program && JSON.stringify(program.getSourceFiles().map(f => f.fileName))}.`);
|
||||
throw new Error(`Could not find sourceFile: '${fileName}'.`);
|
||||
}
|
||||
return sourceFile;
|
||||
}
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user