Skip to content

Commit 3fc03e6

Browse files
committed
Fix some stuff
1 parent d343127 commit 3fc03e6

File tree

1 file changed

+1
-14
lines changed

1 file changed

+1
-14
lines changed

src/commands/createFunctionApp/containerImage/detectDockerfile.ts

Lines changed: 1 addition & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -5,27 +5,14 @@
55

66
import { AzExtFsExtra, nonNullProp, type IActionContext, type IAzureQuickPickItem } from '@microsoft/vscode-azext-utils';
77
import * as path from 'path';
8-
import { RelativePattern, workspace, type MessageItem, type Uri, type WorkspaceFolder } from 'vscode';
8+
import { RelativePattern, workspace, type MessageItem, type Uri } from 'vscode';
99
import { browseItem, dockerfileGlobPattern } from '../../../constants';
1010
import { getAzureContainerAppsApi } from '../../../getExtensionApi';
1111
import { localize } from '../../../localize';
1212
import { type ICreateFunctionAppContext } from '../../../tree/SubscriptionTreeItem';
13-
import { getRootWorkspaceFolder } from '../../../utils/workspace';
1413
import { tryGetFunctionProjectRoot } from '../../createNewProject/verifyIsProject';
1514

1615
export async function detectDockerfile(context: ICreateFunctionAppContext): Promise<string | undefined> {
17-
if (!workspace.workspaceFolders?.length) {
18-
return undefined;
19-
}
20-
21-
try {
22-
context.workspaceFolder ??= await getRootWorkspaceFolder() as WorkspaceFolder;
23-
} catch {
24-
// If the user cancels workspace folder selection (e.g., in a multi-root workspace),
25-
// skip dockerfile detection rather than failing the entire creation flow
26-
return undefined;
27-
}
28-
2916
if (!context.workspaceFolder) {
3017
return undefined;
3118
}

0 commit comments

Comments
 (0)