mirror of
https://github.com/ckaczor/azuredatastudio.git
synced 2026-02-16 10:58:30 -05:00
Have resource deployment providers return disposables (#13690)
* Add dependent field provider to resource deployment * Change name to value provider service * Add error handling * providerId -> id * Set dropdown value correctly * missed id * back to providerId * fix updating missed id * Make resource deployment providers disposable
This commit is contained in:
@@ -109,7 +109,7 @@ export async function activate(context: vscode.ExtensionContext): Promise<azurec
|
||||
// Don't block on this since there's a bit of a circular dependency here with the extension activation since resource deployment
|
||||
// depends on this extension too. It's fine to wait a bit for that to finish before registering the provider
|
||||
vscode.extensions.getExtension(resourceDeployment.extension.name).activate().then((api: resourceDeployment.IExtension) => {
|
||||
api.registerValueProvider({
|
||||
context.subscriptions.push(api.registerValueProvider({
|
||||
id: 'subscription-id-to-tenant-id',
|
||||
getValue: async (triggerValue: string) => {
|
||||
if (triggerValue === '') {
|
||||
@@ -137,7 +137,7 @@ export async function activate(context: vscode.ExtensionContext): Promise<azurec
|
||||
console.error(`Unable to find subscription with ID ${triggerValue} when mapping subscription ID to tenant ID`);
|
||||
return '';
|
||||
}
|
||||
});
|
||||
}));
|
||||
});
|
||||
|
||||
return {
|
||||
|
||||
Reference in New Issue
Block a user