update auth extensions to use packageJSON property instead

This commit is contained in:
Tyler Leonhardt
2021-07-23 11:48:29 -07:00
parent a1b4b8d303
commit c1b4cf00b9
2 changed files with 2 additions and 2 deletions

View File

@@ -10,7 +10,7 @@ import TelemetryReporter from 'vscode-extension-telemetry';
export const DEFAULT_SCOPES = 'https://management.core.windows.net/.default offline_access';
export async function activate(context: vscode.ExtensionContext) {
const { name, version, aiKey } = require('../package.json') as { name: string, version: string, aiKey: string };
const { name, version, aiKey } = context.extension.packageJSON as { name: string, version: string, aiKey: string };
const telemetryReporter = new TelemetryReporter(name, version, aiKey);
const loginService = new AzureActiveDirectoryService(context);