mirror of
https://github.com/Azure/cosmos-explorer.git
synced 2025-03-06 18:07:11 +00:00
Make sure proxy endpoints return in all cases.
This commit is contained in:
parent
7b650fd58a
commit
8c1d27bf30
@ -111,7 +111,7 @@ export const requestPlugin: Cosmos.Plugin<any> = async (requestContext, diagnost
|
||||
requestContext.headers["x-ms-proxy-target"] = endpoint();
|
||||
console.log(`REQUEST CONTEXT PROXY: ${JSON.stringify(requestContext.headers["x-ms-proxy-target"])}`);
|
||||
console.log(`WRITE ENABLED ON ENDPOINT: ${userContext.writeEnabledInSelectedRegion}`);
|
||||
// return await next(requestContext);
|
||||
return await next(requestContext);
|
||||
|
||||
// try {
|
||||
// return await next(requestContext);
|
||||
@ -122,11 +122,11 @@ export const requestPlugin: Cosmos.Plugin<any> = async (requestContext, diagnost
|
||||
// };
|
||||
// }
|
||||
|
||||
try {
|
||||
return await next(requestContext);
|
||||
} catch (error) {
|
||||
console.log(error.code);
|
||||
}
|
||||
// try {
|
||||
// return await next(requestContext);
|
||||
// } catch (error) {
|
||||
// console.log(error.code);
|
||||
// }
|
||||
};
|
||||
|
||||
export const endpoint = () => {
|
||||
|
Loading…
x
Reference in New Issue
Block a user