diff --git a/extension/tasks/dependabotV2/utils/azure-devops/AzureDevOpsWebApiClient.ts b/extension/tasks/dependabotV2/utils/azure-devops/AzureDevOpsWebApiClient.ts index 95e9e5d9..97fe6cad 100644 --- a/extension/tasks/dependabotV2/utils/azure-devops/AzureDevOpsWebApiClient.ts +++ b/extension/tasks/dependabotV2/utils/azure-devops/AzureDevOpsWebApiClient.ts @@ -479,7 +479,7 @@ export class AzureDevOpsWebApiClient { const projects = await core.getProjects(); const projectGuid = projects?.find((p) => p.name === project)?.id; const properties = await core.getProjectProperties(projectGuid); - return properties.map((p) => ({ [p.name]: p.value })).reduce((a, b) => ({ ...a, ...b }), {}); + return properties?.map((p) => ({ [p.name]: p.value }))?.reduce((a, b) => ({ ...a, ...b }), {}); } catch (e) { error(`Failed to get project properties: ${e}`); console.debug(e); // Dump the error stack trace to help with debugging