File tree Expand file tree Collapse file tree 2 files changed +5
-1
lines changed
src/vs/workbench/contrib/scm/browser Expand file tree Collapse file tree 2 files changed +5
-1
lines changed Original file line number Diff line number Diff line change @@ -112,7 +112,6 @@ export class SCMActiveRepositoryController extends Disposable implements IWorkbe
112112
113113 this . _register ( autorunWithStore ( ( reader , store ) => {
114114 this . logService . trace ( '[SCMActiveRepositoryController][updateStatusBarAutorun] start' ) ;
115- this . _repositories . read ( reader ) ;
116115 const repository = this . scmViewService . activeRepository . read ( reader ) ;
117116 const commands = repository ?. provider . statusBarCommands . read ( reader ) ;
118117
Original file line number Diff line number Diff line change @@ -387,6 +387,11 @@ export class SCMViewService implements ISCMViewService {
387387 this . focus ( this . visibleRepositories [ 0 ] ) ;
388388 }
389389
390+ // Check if the last repository was removed
391+ if ( removed . length === 1 && this . _repositories . length === 0 ) {
392+ this . _onDidFocusRepository . fire ( undefined ) ;
393+ }
394+
390395 // Check if the pinned repository was removed
391396 if ( removed . length === 1 && removed [ 0 ] . repository === this . _activeRepositoryPinnedObs . get ( ) ) {
392397 this . _activeRepositoryPinnedObs . set ( undefined , undefined ) ;
You can’t perform that action at this time.
0 commit comments