From c86c4665f8d052fec06d3c0e867ce4623e92c128 Mon Sep 17 00:00:00 2001 From: anabellabuckvar <41971124+anabellabuckvar@users.noreply.github.com> Date: Tue, 19 Mar 2024 11:40:26 -0400 Subject: [PATCH] DOP-4414 entitlements repos --- src/repositories/repoEntitlementsRepository.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/repositories/repoEntitlementsRepository.ts b/src/repositories/repoEntitlementsRepository.ts index f9cdcde26..e878b7458 100644 --- a/src/repositories/repoEntitlementsRepository.ts +++ b/src/repositories/repoEntitlementsRepository.ts @@ -73,7 +73,7 @@ export class RepoEntitlementsRepository extends BaseRepository { `Mongo Timeout Error: Timedout while retrieving entitlements for ${slackUserId}` ); // if user has specific entitlements - if ((entitlementsObject?.repos?.length ?? 0) > 0) { + if (entitlementsObject?.repos && entitlementsObject.repos.length > 0) { return { repos: entitlementsObject.repos, github_username: entitlementsObject.github_username,