From 431f59d90efc854e2699348b364c3a871234ad2b Mon Sep 17 00:00:00 2001 From: alexyaang <59073590+alexyaang@users.noreply.github.com> Date: Fri, 22 Sep 2023 11:37:18 -0400 Subject: [PATCH] show not available message when there no registries provider available --- src/tree/registries/UnifiedRegistryTreeDataProvider.ts | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/tree/registries/UnifiedRegistryTreeDataProvider.ts b/src/tree/registries/UnifiedRegistryTreeDataProvider.ts index 23a7bf6b34..057334589c 100644 --- a/src/tree/registries/UnifiedRegistryTreeDataProvider.ts +++ b/src/tree/registries/UnifiedRegistryTreeDataProvider.ts @@ -127,7 +127,8 @@ export class UnifiedRegistryTreeDataProvider implements vscode.TreeDataProvider< }); } - const picked = await vscode.window.showQuickPick(picks, { placeHolder: vscode.l10n.t('Select a registry provider to use') }); + const pickPrompt = picks && picks.length > 0 ? vscode.l10n.t('Select a registry provider to use') : vscode.l10n.t('No registry providers are available for connection'); + const picked = await vscode.window.showQuickPick(picks, { placeHolder: pickPrompt }); if (!picked) { return; }