Skip to content

Commit 1ab6fd4

Browse files
author
Uroš Marolt
committed
Fixed linkedin member redis cache timeout value
1 parent 592d534 commit 1ab6fd4

1 file changed

Lines changed: 8 additions & 4 deletions

File tree

backend/src/serverless/integrations/services/integrations/premium/linkedinIntegrationService.ts

Lines changed: 8 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -446,10 +446,14 @@ export class LinkedinIntegrationService extends IntegrationServiceBase {
446446
} else if (isLinkedInOrganization(memberUrn)) {
447447
const userId = getLinkedInOrganizationId(memberUrn)
448448

449-
const organizationString = await membersCache.getOrAdd(userId, async () => {
450-
const organization = await getOrganization(context.pipelineData.pizzlyId, userId, log)
451-
return JSON.stringify(organization)
452-
})
449+
const organizationString = await membersCache.getOrAdd(
450+
userId,
451+
async () => {
452+
const organization = await getOrganization(context.pipelineData.pizzlyId, userId, log)
453+
return JSON.stringify(organization)
454+
},
455+
24 * 60 * 60,
456+
)
453457

454458
const organization = JSON.parse(organizationString)
455459

0 commit comments

Comments
 (0)