Fix issue with query string on sensitive APIs

This commit is contained in:
adamkingsbury 2022-09-09 22:16:44 +01:00
parent b1bbe69827
commit 70c3e5ee62
1 changed files with 4 additions and 1 deletions

View File

@ -217,7 +217,10 @@ class RestIntegration implements IntegrationBase {
}
}
const main = `${path}?${queryString}`
if (queryString) {
queryString = "?" + queryString
}
const main = `${path}${queryString}`
let complete = main
if (this.config.url && !main.startsWith("http")) {
complete = !this.config.url ? main : `${this.config.url}/${main}`