Async import of the appStore packages#1
Conversation
|
@codex review |
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: e043a5efd8
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
| bookingToDelete.user.credentials | ||
| .filter((credential) => credential.type.endsWith("_calendar")) | ||
| .forEach(async (credential) => { | ||
| const calendar = getCalendar(credential); | ||
| const calendar = await getCalendar(credential); | ||
| for (const updBooking of updatedBookings) { | ||
| const bookingRef = updBooking.references.find((ref) => ref.type.includes("_calendar")); | ||
| if (bookingRef) { |
There was a problem hiding this comment.
Await recurring calendar deletions before Promise.all
The recurring-event branch now uses an async forEach and pushes into apiDeletes only after await getCalendar/await calendar?.deleteEvent(...) completes. Because forEach does not await, the handler can reach the later Promise.all(prismaPromises.concat(apiDeletes)) before these deletions are even added, so recurring cancellations may return without waiting for calendar deletions and failures will be unobserved. Consider collecting promises with map + Promise.all or switching to a for...of loop that awaits and pushes promises synchronously.
Useful? React with 👍 / 👎.
Test 2nn---nReplicated from ai-code-review-evaluation/cal.com-cursor#2