Skip to content

Commit 517a053

Browse files
committed
Rename storagePath -> qlStoragePath
1 parent 4b01374 commit 517a053

File tree

1 file changed

+11
-11
lines changed

1 file changed

+11
-11
lines changed

extensions/ql-vscode/src/skeleton-query-wizard.ts

Lines changed: 11 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -27,7 +27,7 @@ export const QUERY_LANGUAGE_TO_DATABASE_REPO: QueryLanguagesToDatabaseMap = {
2727
export class SkeletonQueryWizard {
2828
private language: string | undefined;
2929
private fileName = "example.ql";
30-
private storagePath: string | undefined;
30+
private qlPackStoragePath: string | undefined;
3131

3232
constructor(
3333
private readonly cliServer: CodeQLCliServer,
@@ -49,7 +49,7 @@ export class SkeletonQueryWizard {
4949
return;
5050
}
5151

52-
this.storagePath = this.getFirstStoragePath();
52+
this.qlPackStoragePath = this.getFirstStoragePath();
5353

5454
const skeletonPackAlreadyExists = isFolderAlreadyInWorkspace(
5555
this.folderName,
@@ -72,12 +72,12 @@ export class SkeletonQueryWizard {
7272
}
7373

7474
private async openExampleFile() {
75-
if (this.folderName === undefined || this.storagePath === undefined) {
75+
if (this.folderName === undefined || this.qlPackStoragePath === undefined) {
7676
throw new Error("Path to folder is undefined");
7777
}
7878

7979
const queryFileUri = Uri.file(
80-
join(this.storagePath, this.folderName, this.fileName),
80+
join(this.qlPackStoragePath, this.folderName, this.fileName),
8181
);
8282

8383
try {
@@ -138,7 +138,7 @@ export class SkeletonQueryWizard {
138138
this.folderName,
139139
this.language as QueryLanguage,
140140
this.cliServer,
141-
this.storagePath,
141+
this.qlPackStoragePath,
142142
);
143143

144144
await qlPackGenerator.generate();
@@ -166,7 +166,7 @@ export class SkeletonQueryWizard {
166166
this.folderName,
167167
this.language as QueryLanguage,
168168
this.cliServer,
169-
this.storagePath,
169+
this.qlPackStoragePath,
170170
);
171171

172172
this.fileName = await this.determineNextFileName(this.folderName);
@@ -179,11 +179,11 @@ export class SkeletonQueryWizard {
179179
}
180180

181181
private async determineNextFileName(folderName: string): Promise<string> {
182-
if (this.storagePath === undefined) {
182+
if (this.qlPackStoragePath === undefined) {
183183
throw new Error("Workspace storage path is undefined");
184184
}
185185

186-
const folderUri = Uri.file(join(this.storagePath, folderName));
186+
const folderUri = Uri.file(join(this.qlPackStoragePath, folderName));
187187
const files = await workspace.fs.readDirectory(folderUri);
188188
const qlFiles = files.filter(([filename, _fileType]) =>
189189
filename.match(/example[0-9]*.ql/),
@@ -193,7 +193,7 @@ export class SkeletonQueryWizard {
193193
}
194194

195195
private async downloadDatabase() {
196-
if (this.storagePath === undefined) {
196+
if (this.qlPackStoragePath === undefined) {
197197
throw new Error("Workspace storage path is undefined");
198198
}
199199

@@ -220,7 +220,7 @@ export class SkeletonQueryWizard {
220220
await databaseFetcher.downloadGitHubDatabase(
221221
chosenRepo,
222222
this.databaseManager,
223-
this.storagePath,
223+
this.qlPackStoragePath,
224224
this.credentials,
225225
this.progress,
226226
this.token,
@@ -234,7 +234,7 @@ export class SkeletonQueryWizard {
234234
throw new Error("Language is undefined");
235235
}
236236

237-
if (this.storagePath === undefined) {
237+
if (this.qlPackStoragePath === undefined) {
238238
throw new Error("Workspace storage path is undefined");
239239
}
240240

0 commit comments

Comments
 (0)