Skip to content

Commit cd12e96

Browse files
author
Akos Kitta
committed
fix: missing refresh to set local URI to node
Signed-off-by: Akos Kitta <[email protected]>
1 parent a02db45 commit cd12e96

File tree

1 file changed

+12
-12
lines changed

1 file changed

+12
-12
lines changed

arduino-ide-extension/src/browser/widgets/cloud-sketchbook/cloud-sketchbook-tree.ts

+12-12
Original file line numberDiff line numberDiff line change
@@ -343,18 +343,18 @@ export class CloudSketchbookTree extends SketchbookTree {
343343
task: (node: CloudSketchbookTree.CloudSketchDirNode) => MaybePromise<T>,
344344
noProgress = false
345345
): 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;
358358
}
359359

360360
private taskMessage(

0 commit comments

Comments
 (0)