@@ -468,24 +468,31 @@ module.exports =
468
468
return ' Indexing ' + path
469
469
470
470
service .onDidStartIndexing ({path}) =>
471
- indexBusyMessageMap[path] = @busySignalService .reportBusy (getBaseMessageForPath (path), {
471
+ if not indexBusyMessageMap .has (path)
472
+ indexBusyMessageMap .set (path, new Array ())
473
+
474
+ indexBusyMessageMap .get (path).push (@busySignalService .reportBusy (getBaseMessageForPath (path), {
472
475
waitingFor : ' computer' ,
473
476
revealTooltip : true
474
- })
477
+ }))
475
478
476
479
service .onDidFinishIndexing ({path}) =>
477
- if path of indexBusyMessageMap
478
- indexBusyMessageMap[path].dispose ()
479
- delete indexBusyMessageMap[path]
480
+ return if not indexBusyMessageMap .has (path)
481
+
482
+ indexBusyMessageMap .get (path).forEach ((busyMessage ) => busyMessage .dispose ())
483
+ indexBusyMessageMap .delete (path)
480
484
481
485
service .onDidFailIndexing ({path}) =>
482
- if path of indexBusyMessageMap
483
- indexBusyMessageMap[path].dispose ()
484
- delete indexBusyMessageMap[path]
486
+ return if not indexBusyMessageMap .has (path)
487
+
488
+ indexBusyMessageMap .get (path).forEach ((busyMessage ) => busyMessage .dispose ())
489
+ indexBusyMessageMap .delete (path)
485
490
486
491
service .onDidIndexingProgress ({path, percentage}) =>
487
- if indexBusyMessageMap[path]?
488
- indexBusyMessageMap[path].setTitle (getBaseMessageForPath (path) + " (" + percentage .toFixed (2 ) + " %)" )
492
+ return if not indexBusyMessageMap .has (path)
493
+
494
+ indexBusyMessageMap .get (path).forEach (busyMessage) =>
495
+ busyMessage .setTitle (getBaseMessageForPath (path) + " (" + percentage .toFixed (2 ) + " %)" )
489
496
490
497
### *
491
498
* @return {Promise}
0 commit comments