fix: amend getSecurityHotspotsUrl to conditionally remove project path

Signed-off-by: Matthew Thomas <matthewthomasgb@gmail.com>
This commit is contained in:
Matthew Thomas
2023-04-13 14:07:58 +01:00
parent adf027d6c0
commit 5a368d12bc
2 changed files with 8 additions and 3 deletions
+3 -3
View File
@@ -130,9 +130,9 @@ export class SonarQubeClient implements SonarQubeApi {
'en-US',
)}&resolved=false&view=list`,
getSecurityHotspotsUrl: () =>
`${baseUrl}project/security_hotspots?id=${encodeURIComponent(
componentKey,
)}`,
`${baseUrl}${
baseUrl === 'https://sonarcloud.io/' ? 'project/' : ''
}security_hotspots?id=${encodeURIComponent(componentKey)}`,
};
}
}