Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ export async function detectDockerfile(context: ICreateFunctionAppContext): Prom
context.rootPath = workspacePath;

//check for host.json location
if (!(await isFunctionProject(workspacePath))) {
if (await isFunctionProject(workspacePath)) {
const files = (await findFiles(context.workspaceFolder, `*/${hostFileName}`));
if (files.length === 0) {
Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

You honestly probably don't need these checks anymore either.

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Talked offline and the checks are still needed.

throw new Error(localize('noHostJson', 'No host.json file found in the current workspace.'));
Expand Down