Skip to content

Commit

Permalink
More logging
Browse files Browse the repository at this point in the history
  • Loading branch information
joeauyeung committed Feb 7, 2025
1 parent 7b64eea commit c3ddc3e
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions packages/app-store/salesforce/lib/CrmService.ts
Original file line number Diff line number Diff line change
Expand Up @@ -230,14 +230,14 @@ export default class SalesforceCRMService implements CRM {
// User has not configured "Allow Users to Relate Multiple Contacts to Tasks and Events"
// proceeding to create the event using just the first attendee as the primary WhoId
return await this.salesforceCreateEventApiCall(event, {
WhoId: firstContact,
WhoId: firstContact.id,
}).catch((reason) => Promise.reject(reason));
}
log.error(`Error creating event: ${JSON.stringify(reason)}`);

// Try creating a simple object without additional records
return await this.salesforceCreateEventApiCall(event, {
EventWhoIds: eventWhoIds,
WhoId: firstContact.id,
...(ownerId && { OwnerId: ownerId }),
}).catch((reason) => {
log.error(`Error creating simple event: ${JSON.stringify(reason)}`);
Expand Down

0 comments on commit c3ddc3e

Please sign in to comment.