From 55786936352bac34ed97d7de59bfd8f18b4c96d7 Mon Sep 17 00:00:00 2001 From: Amir Omidi Date: Fri, 6 Mar 2020 15:10:46 -0800 Subject: [PATCH] Fix the svg issue (#9487) --- .../azurecore/src/account-provider/azureAccountProvider2.ts | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/extensions/azurecore/src/account-provider/azureAccountProvider2.ts b/extensions/azurecore/src/account-provider/azureAccountProvider2.ts index 18a3a107b9..d54d6f1c3a 100644 --- a/extensions/azurecore/src/account-provider/azureAccountProvider2.ts +++ b/extensions/azurecore/src/account-provider/azureAccountProvider2.ts @@ -254,9 +254,14 @@ export class AzureAccountProvider implements azdata.AccountProvider { sendFile(res, path.join(mediaPath, 'landing.css'), 'text/css; charset=utf-8').catch(console.error); }; + const svg = (req: http.IncomingMessage, res: http.ServerResponse, reqUrl: url.UrlWithParsedQuery) => { + sendFile(res, path.join(mediaPath, 'SignIn.svg'), 'image/svg+xml').catch(console.error); + }; + pathMappings.set('/signin', initialSignIn); pathMappings.set('/callback', authCallback); pathMappings.set('/landing.css', css); + pathMappings.set('/SignIn.svg', svg); } private async makeWebRequest(accessToken: TokenResponse, uri: string): Promise {