Skip to content

Commit 6e5188f

Browse files
committed
Replace Uri.parse by Uri.file
1 parent ddbe3cd commit 6e5188f

File tree

2 files changed

+1
-5
lines changed

2 files changed

+1
-5
lines changed

extensions/ql-vscode/src/databases/local-databases.ts

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1153,9 +1153,6 @@ export class DatabaseManager extends DisposableObject {
11531153

11541154
private isExtensionControlledLocation(uri: vscode.Uri) {
11551155
const storageUri = this.ctx.storageUri || this.ctx.globalStorageUri;
1156-
// the uri.fsPath function on windows returns a lowercase drive letter,
1157-
// but storagePath will have an uppercase drive letter. Be sure to compare
1158-
// URIs to URIs only
11591156
if (storageUri) {
11601157
return containsPath(storageUri.fsPath, uri.fsPath, process.platform);
11611158
}

extensions/ql-vscode/test/vscode-tests/minimal-workspace/local-databases.test.ts

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -80,8 +80,7 @@ describe("local databases", () => {
8080
dynamicProperties: {
8181
// pretend like databases added in the temp dir are controlled by the extension
8282
// so that they are deleted upon removal
83-
storagePath: () => extensionContextStoragePath,
84-
storageUri: () => Uri.parse(extensionContextStoragePath),
83+
storageUri: () => Uri.file(extensionContextStoragePath),
8584
},
8685
},
8786
);

0 commit comments

Comments
 (0)