Skip to content

Commit 8b00354

Browse files
authored
Ensure that showOpenDialog returns correct file URI (#13208)
Use `URI.file` instead of manually reconstructing the URI from the received file path in plugin ext. This ensures that directories or files that contain a hash are not wrongly added to the fragment component of the URI and aligns it with the expected behavior of VS Code. Fixes #13074 Contributed on behalf of ST Microelectronics
1 parent 29c6b67 commit 8b00354

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

packages/plugin-ext/src/plugin/dialogs.ts

+1-1
Original file line numberDiff line numberDiff line change
@@ -41,7 +41,7 @@ export class DialogsExtImpl {
4141
if (result) {
4242
const uris = [];
4343
for (let i = 0; i < result.length; i++) {
44-
const uri = URI.parse('file://' + result[i]);
44+
const uri = URI.file(result[i]);
4545
uris.push(uri);
4646
}
4747
resolve(uris);

0 commit comments

Comments
 (0)