mirror of
https://github.com/microsoft/monaco-editor.git
synced 2025-12-22 18:32:56 +01:00
Fix a crash in getValidSourceFile when the text content is empty
This commit is contained in:
parent
778ace10c0
commit
3237250330
1 changed files with 1 additions and 1 deletions
|
|
@ -97,7 +97,7 @@ export class TypeScriptWorker implements ts.LanguageServiceHost, monaco.language
|
|||
|
||||
getScriptSnapshot(fileName: string): ts.IScriptSnapshot | undefined {
|
||||
const text = this._getScriptText(fileName);
|
||||
if (!text) {
|
||||
if (text === undefined) {
|
||||
return;
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue