File tree 3 files changed +7
-4
lines changed
3 files changed +7
-4
lines changed Original file line number Diff line number Diff line change 1
1
{
2
- "name" : " ng-language-service " ,
2
+ "name" : " ng-template " ,
3
3
"displayName" : " Angular Language Service" ,
4
4
"description" : " Editor services for Angular templates" ,
5
- "version" : " 0.1.6 " ,
5
+ "version" : " 0.1.7 " ,
6
6
"publisher" : " Angular" ,
7
7
"icon" : " angular.png" ,
8
8
"engines" : {
Original file line number Diff line number Diff line change 1
1
{
2
- "name" : " ng-language-service " ,
2
+ "name" : " ng-template " ,
3
3
"description" : " Angular Language Service." ,
4
- "version" : " 0.1.6 " ,
4
+ "version" : " 0.1.7 " ,
5
5
"author" : " Angular" ,
6
6
"license" : " MIT" ,
7
7
"engines" : {
Original file line number Diff line number Diff line change @@ -2749,6 +2749,7 @@ export class LineNode implements LineCollection {
2749
2749
// assume (rangeStart < this.totalChars) && (rangeLength <= this.totalChars)
2750
2750
let childIndex = 0 ;
2751
2751
let child = this . children [ 0 ] ;
2752
+ if ( ! child ) return ;
2752
2753
let childCharCount = child . charCount ( ) ;
2753
2754
// find sub-tree containing start
2754
2755
let adjustedStart = rangeStart ;
@@ -2757,6 +2758,7 @@ export class LineNode implements LineCollection {
2757
2758
adjustedStart -= childCharCount ;
2758
2759
childIndex ++ ;
2759
2760
child = this . children [ childIndex ] ;
2761
+ if ( ! child ) break ;
2760
2762
childCharCount = child . charCount ( ) ;
2761
2763
}
2762
2764
// Case I: both start and end of range in same subtree
@@ -2781,6 +2783,7 @@ export class LineNode implements LineCollection {
2781
2783
adjustedLength -= childCharCount ;
2782
2784
childIndex ++ ;
2783
2785
child = this . children [ childIndex ] ;
2786
+ if ( ! child ) break ;
2784
2787
childCharCount = child . charCount ( ) ;
2785
2788
}
2786
2789
if ( adjustedLength > 0 ) {
You can’t perform that action at this time.
0 commit comments