Added support for {org}.visualstudio.com domains used by Azure DevOps
Signed-off-by: Andre Wanlin <awanlin@spotify.com> Address CodeQL comments Signed-off-by: Andre Wanlin <awanlin@spotify.com> Another correction Signed-off-by: Andre Wanlin <awanlin@spotify.com> Fixed casing Signed-off-by: Andre Wanlin <awanlin@spotify.com> Adjusted to be more secure based on feedback Signed-off-by: Andre Wanlin <awanlin@spotify.com> Tighten up endsWith Signed-off-by: Andre Wanlin <awanlin@spotify.com> Corrections to TSDoc comment Signed-off-by: Andre Wanlin <awanlin@spotify.com> Changes based on feedback Signed-off-by: Andre Wanlin <awanlin@spotify.com> Correct URL for discovery Signed-off-by: Andre Wanlin <awanlin@spotify.com> Updated docs Signed-off-by: Andre Wanlin <awanlin@spotify.com> Updated changeset Signed-off-by: Andre Wanlin <awanlin@spotify.com>
This commit is contained in:
@@ -75,12 +75,16 @@ export async function codeSearch(
|
||||
: `https://${azureConfig.host}`;
|
||||
const searchUrl = `${searchBaseUrl}/${org}/_apis/search/codesearchresults?api-version=6.0-preview.1`;
|
||||
|
||||
const url = azureConfig.host.endsWith('.visualstudio.com')
|
||||
? `https://${azureConfig.host}`
|
||||
: `https://${azureConfig.host}/${org}`;
|
||||
|
||||
let items: CodeSearchResultItem[] = [];
|
||||
let hasMorePages = true;
|
||||
|
||||
do {
|
||||
const credentials = await credentialsProvider.getCredentials({
|
||||
url: `https://${azureConfig.host}/${org}`,
|
||||
url,
|
||||
});
|
||||
|
||||
const searchRequestBody: CodeSearchRequest = {
|
||||
|
||||
Reference in New Issue
Block a user