Fix the svg issue (#9487)

This commit is contained in:
Amir Omidi
2020-03-06 15:10:46 -08:00
committed by GitHub
parent 9cc31bee62
commit 5578693635

View File

@@ -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<any> {