Fix formatting.

This commit is contained in:
Craig Boger (from Dev Box) 2025-03-03 17:11:47 -08:00
parent fa99c54efc
commit 13e0160a46
2 changed files with 3 additions and 4 deletions

View File

@ -108,7 +108,7 @@ export const tokenProvider = async (requestInfo: Cosmos.RequestInfo) => {
export const requestPlugin: Cosmos.Plugin<any> = async (requestContext, diagnosticNode, next) => { export const requestPlugin: Cosmos.Plugin<any> = async (requestContext, diagnosticNode, next) => {
requestContext.endpoint = new URL(configContext.PROXY_PATH, window.location.href).href; requestContext.endpoint = new URL(configContext.PROXY_PATH, window.location.href).href;
requestContext.headers["x-ms-proxy-target"] = endpoint(); requestContext.headers["x-ms-proxy-target"] = endpoint();
return await next(requestContext); return next(requestContext);
}; };
export const endpoint = () => { export const endpoint = () => {
@ -219,6 +219,5 @@ export function client(): Cosmos.CosmosClient {
} }
_client = new Cosmos.CosmosClient(options); _client = new Cosmos.CosmosClient(options);
return _client; return _client;
} }

View File

@ -299,7 +299,7 @@ async function configureHostedWithAAD(config: AAD): Promise<Explorer> {
`Configuring Data Explorer for ${userContext.apiType} account ${account.name}`, `Configuring Data Explorer for ${userContext.apiType} account ${account.name}`,
"Explorer/configureHostedWithAAD", "Explorer/configureHostedWithAAD",
); );
if (userContext.apiType === "SQL" && userContext.authType === AuthType.AAD) { if (userContext.apiType === "SQL") {
checkAndUpdateSelectedRegionalEndpoint(); checkAndUpdateSelectedRegionalEndpoint();
} }
if (!userContext.features.enableAadDataPlane) { if (!userContext.features.enableAadDataPlane) {
@ -556,7 +556,7 @@ async function configurePortal(): Promise<Explorer> {
const { databaseAccount: account, subscriptionId, resourceGroup } = userContext; const { databaseAccount: account, subscriptionId, resourceGroup } = userContext;
if (userContext.apiType === "SQL" && userContext.authType === AuthType.AAD) { if (userContext.apiType === "SQL") {
checkAndUpdateSelectedRegionalEndpoint(); checkAndUpdateSelectedRegionalEndpoint();
} }