File tree 1 file changed +12
-12
lines changed
arduino-ide-extension/src/browser/widgets/cloud-sketchbook
1 file changed +12
-12
lines changed Original file line number Diff line number Diff line change @@ -343,18 +343,18 @@ export class CloudSketchbookTree extends SketchbookTree {
343
343
task : ( node : CloudSketchbookTree . CloudSketchDirNode ) => MaybePromise < T > ,
344
344
noProgress = false
345
345
) : Promise < T > {
346
- if ( noProgress ) {
347
- return task ( node ) ;
348
- }
349
- const name = node . uri . path . name ;
350
- return ExecuteWithProgress . withProgress (
351
- this . taskMessage ( state , name ) ,
352
- this . messageService ,
353
- async ( progress ) => {
354
- progress . report ( { work : { done : 0 , total : NaN } } ) ;
355
- return task ( node ) ;
356
- }
357
- ) ;
346
+ const result = await ( noProgress
347
+ ? task ( node )
348
+ : ExecuteWithProgress . withProgress (
349
+ this . taskMessage ( state , node . uri . path . name ) ,
350
+ this . messageService ,
351
+ async ( progress ) => {
352
+ progress . report ( { work : { done : 0 , total : NaN } } ) ;
353
+ return task ( node ) ;
354
+ }
355
+ ) ) ;
356
+ await this . refresh ( node ) ;
357
+ return result ;
358
358
}
359
359
360
360
private taskMessage (
You can’t perform that action at this time.
0 commit comments