Update isCloud method to resolve Incomplete URL substring sanitization error

Signed-off-by: Camgoz, Fatih <fatih.camgoz@rbc.com>
This commit is contained in:
Camgoz, Fatih
2025-05-16 13:39:50 -04:00
parent be82d839d4
commit f8df253261
2 changed files with 25 additions and 5 deletions
@@ -46,8 +46,18 @@ interface CodeSearchRequest {
};
}
const isCloud = (host: string) =>
host === 'dev.azure.com' || host.endsWith('visualstudio.com');
const isCloud = (host: string) => {
if (host === 'dev.azure.com') {
return true;
}
if (host === 'visualstudio.com' || host.endsWith('.visualstudio.com')) {
return true;
}
return false;
};
const PAGE_SIZE = 1000;
// codeSearch returns all files that matches the given search path.