@@ -675,10 +675,12 @@ namespace ts.server {
675675 isInferred : this . projectKind === ProjectKind . Inferred ,
676676 options : this . getCompilerOptions ( )
677677 } ;
678+ const updatedFileNames = this . updatedFileNames ;
679+ this . updatedFileNames = undefined ;
678680 // check if requested version is the same that we have reported last time
679681 if ( this . lastReportedFileNames && lastKnownVersion === this . lastReportedVersion ) {
680- // if current structure version is the same - return info witout any changes
681- if ( this . projectStructureVersion == this . lastReportedVersion && ! this . updatedFileNames ) {
682+ // if current structure version is the same - return info without any changes
683+ if ( this . projectStructureVersion == this . lastReportedVersion && ! updatedFileNames ) {
682684 return { info, projectErrors : this . projectErrors } ;
683685 }
684686 // compute and return the difference
@@ -687,7 +689,7 @@ namespace ts.server {
687689
688690 const added : string [ ] = [ ] ;
689691 const removed : string [ ] = [ ] ;
690- const updated : string [ ] = getOwnKeys ( this . updatedFileNames ) ;
692+ const updated : string [ ] = getOwnKeys ( updatedFileNames ) ;
691693 for ( const id in currentFiles ) {
692694 if ( ! hasProperty ( lastReportedFileNames , id ) ) {
693695 added . push ( id ) ;
@@ -700,7 +702,6 @@ namespace ts.server {
700702 }
701703 this . lastReportedFileNames = currentFiles ;
702704 this . lastReportedVersion = this . projectStructureVersion ;
703- this . updatedFileNames = undefined ;
704705 return { info, changes : { added, removed, updated } , projectErrors : this . projectErrors } ;
705706 }
706707 else {
0 commit comments