Remove query name from query ID for MRVA queries

This commit is contained in:
Koen Vlaswinkel
2022-09-08 13:59:26 +02:00
parent 24652a84e4
commit 181b5d6f7b

View File

@@ -127,7 +127,7 @@ export class RemoteQueriesManager extends DisposableObject {
if (querySubmission?.query) {
const query = querySubmission.query;
const queryId = this.createQueryId(query.queryName);
const queryId = this.createQueryId();
await this.prepareStorageDirectory(queryId);
await this.storeJsonFile(queryId, 'query.json', query);
@@ -264,11 +264,10 @@ export class RemoteQueriesManager extends DisposableObject {
/**
* Generates a unique id for this query, suitable for determining the storage location for the downloaded query artifacts.
* @param queryName
* @returns
* @returns A unique id for this query.
*/
private createQueryId(queryName: string): string {
return `${queryName}-${nanoid()}`;
private createQueryId(): string {
return nanoid();
}
/**