File tree Expand file tree Collapse file tree 1 file changed +8
-3
lines changed Expand file tree Collapse file tree 1 file changed +8
-3
lines changed Original file line number Diff line number Diff line change @@ -75,7 +75,8 @@ class TypeHierarchyTreeItem extends vscode.TreeItem {
7575 super ( item . name ) ;
7676 this . description = item . detail ;
7777 this . iconPath = new vscode . ThemeIcon ( 'symbol-class' ) ;
78- let subItems = direction === TypeHierarchyDirection . Children ? item . children : item . parents ;
78+ let subItems = direction === TypeHierarchyDirection . Children ? item . children
79+ : item . parents ;
7980 if ( subItems ) {
8081 if ( subItems . length === 0 ) {
8182 this . collapsibleState = vscode . TreeItemCollapsibleState . None ;
@@ -260,11 +261,15 @@ class TypeHierarchyProvider implements
260261 await this . client . sendRequest ( ResolveTypeHierarchyRequest . type , {
261262 item : element ,
262263 direction : TypeHierarchyDirection . Children ,
263- resolve : 2 // We need 2 levels to understand which collapsible state to use
264+ resolve : 2 // We need 2 levels to understand collapsible state
264265 } ) ;
265266 element . children = resolved ?. children ;
266267 // Cut-of existing sub-children to resolve them later
267- element . children ?. forEach ( x => { if ( x . children ?. length !== 0 ) { x . children = undefined ; } } ) ;
268+ element . children ?. forEach ( x => {
269+ if ( x . children ?. length !== 0 ) {
270+ x . children = undefined ;
271+ }
272+ } ) ;
268273 }
269274 return element . children ?? [ ] ;
270275 }
You can’t perform that action at this time.
0 commit comments