Skip to content

Commit 59909e2

Browse files
committed
Convert folderName property into getter method
1 parent b794427 commit 59909e2

1 file changed

Lines changed: 4 additions & 2 deletions

File tree

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

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -26,7 +26,6 @@ export const QUERY_LANGUAGE_TO_DATABASE_REPO: QueryLanguagesToDatabaseMap = {
2626

2727
export class SkeletonQueryWizard {
2828
private language: string | undefined;
29-
private folderName: string | undefined;
3029
private fileName = "example.ql";
3130
private storagePath: string | undefined;
3231

@@ -41,14 +40,17 @@ export class SkeletonQueryWizard {
4140
this.storagePath = this.workoutStoragePath();
4241
}
4342

43+
private get folderName() {
44+
return `codeql-custom-queries-${this.language}`;
45+
}
46+
4447
public async execute() {
4548
// show quick pick to choose language
4649
this.language = await this.chooseLanguage();
4750
if (!this.language) {
4851
return;
4952
}
5053

51-
this.folderName = `codeql-custom-queries-${this.language}`;
5254
const skeletonPackAlreadyExists = isFolderAlreadyInWorkspace(
5355
this.folderName,
5456
);

0 commit comments

Comments
 (0)