File tree Expand file tree Collapse file tree 3 files changed +24
-2
lines changed Expand file tree Collapse file tree 3 files changed +24
-2
lines changed Original file line number Diff line number Diff line change @@ -168,6 +168,6 @@ export class RepositoriesNode extends SubscribeableViewNode<ViewsWithRepositorie
168168
169169 @debug ( )
170170 private onRepositoriesChanged ( _e : RepositoriesChangeEvent ) {
171- void this . triggerChange ( ) ;
171+ void this . triggerChange ( true ) ;
172172 }
173173}
Original file line number Diff line number Diff line change @@ -30,7 +30,9 @@ export class WorkspaceNode extends ViewNode<WorkspacesView> {
3030 return this . workspace . name ;
3131 }
3232
33- private _children : ViewNode [ ] | undefined ;
33+ private _children :
34+ | ( CommandMessageNode | MessageNode | RepositoryNode | WorkspaceMissingRepositoryNode ) [ ]
35+ | undefined ;
3436
3537 async getChildren ( ) : Promise < ViewNode [ ] > {
3638 if ( this . _children == null ) {
@@ -130,6 +132,16 @@ export class WorkspaceNode extends ViewNode<WorkspacesView> {
130132 }
131133
132134 override refresh ( ) {
135+ if ( this . _children == null ) return ;
136+
137+ if ( this . _children . length ) {
138+ for ( const child of this . _children ) {
139+ if ( 'dispose' in child ) {
140+ child . dispose ( ) ;
141+ }
142+ }
143+ }
144+
133145 this . _children = undefined ;
134146 }
135147}
Original file line number Diff line number Diff line change @@ -55,6 +55,16 @@ export class WorkspacesViewNode extends ViewNode<WorkspacesView> {
5555 @gate ( )
5656 @debug ( )
5757 override refresh ( ) {
58+ if ( this . _children == null ) return ;
59+
60+ if ( this . _children . length ) {
61+ for ( const child of this . _children ) {
62+ if ( 'dispose' in child ) {
63+ child . dispose ( ) ;
64+ }
65+ }
66+ }
67+
5868 this . _children = undefined ;
5969 }
6070}
You can’t perform that action at this time.
0 commit comments