mirror of
https://github.com/microsoft/TypeScript.git
synced 2025-11-18 17:21:48 +00:00
Co-authored-by: Sheetal Nandi <shkamat@microsoft.com>
This commit is contained in:
co-authored by
Sheetal Nandi
parent
a20c69e8df
commit
2b0009c679
@@ -2245,8 +2245,12 @@ export abstract class Project implements LanguageServiceHost, ModuleResolutionHo
|
||||
|
||||
this.getScriptInfo(rootFile)?.editContent(0, originalText.length, updatedText);
|
||||
this.updateGraph();
|
||||
cb(this.program!, originalProgram, (this.program?.getSourceFile(rootFile))!);
|
||||
this.getScriptInfo(rootFile)?.editContent(0, this.program!.getSourceFile(rootFile)!.getText().length, originalText);
|
||||
try {
|
||||
cb(this.program!, originalProgram, (this.program?.getSourceFile(rootFile))!);
|
||||
}
|
||||
finally {
|
||||
this.getScriptInfo(rootFile)?.editContent(0, this.program!.getSourceFile(rootFile)!.getText().length, originalText);
|
||||
}
|
||||
}
|
||||
|
||||
/** @internal */
|
||||
|
||||
Reference in New Issue
Block a user