* fix: validate Round Robin host availability in handleNewBooking
- Add validation to ensure Round Robin events have at least one available non-fixed host
- Throw NoAvailableUsersFound error when no Round Robin hosts are available
- Add unit test to verify the fix works correctly
- Fixes issue where Round Robin events with fixed hosts could be booked without Round Robin hosts
Co-Authored-By: carina@cal.com <c.wollendorfer@me.com>
* test: fix host configuration in Round Robin test
Co-Authored-By: carina@cal.com <c.wollendorfer@me.com>
* test: improve Round Robin test to only make RR host busy
Co-Authored-By: carina@cal.com <c.wollendorfer@me.com>
* fix: correct Round Robin validation to only check when RR hosts assigned
Co-Authored-By: carina@cal.com <c.wollendorfer@me.com>
* fix: refine Round Robin validation to only apply when both fixed and RR hosts present
- Add fixedUserPool.length > 0 condition to validation
- Ensures validation only triggers for specific bug scenario: events with fixed hosts + RR hosts but no available RR hosts
- Prevents blocking normal Round Robin events that only have RR hosts
- Updates test description to reflect more precise validation logic
Co-Authored-By: carina@cal.com <c.wollendorfer@me.com>
* fix: simplify Round Robin validation to resolve E2E test failures
Remove overly restrictive fixedUserPool.length > 0 condition that was
blocking valid Round Robin booking scenarios in E2E tests. The validation
now only checks if Round Robin hosts are assigned but none are available,
which is the intended behavior for the bug fix.
Co-Authored-By: carina@cal.com <c.wollendorfer@me.com>
* fix: restore fixedUserPool condition to Round Robin validation
- Add back fixedUserPool.length > 0 condition to make validation specific to bug scenario
- Only triggers when Round Robin events have both fixed hosts AND Round Robin hosts but no available Round Robin hosts
- Prevents blocking normal Round Robin events that only have Round Robin hosts (like in organization settings E2E test)
- Updates test description to reflect more precise validation logic
Co-Authored-By: carina@cal.com <c.wollendorfer@me.com>
Co-Authored-By: carina@cal.com <c.wollendorfer@me.com>
* throw error if no RR user is available
* add tests
* fix comments
* revert change
* remove comments
---------
Co-authored-by: Devin AI <158243242+devin-ai-integration[bot]@users.noreply.github.com>
Co-authored-by: CarinaWolli <wollencarina@gmail.com>
* Do not import stripe lib in getServerErrorFromUnknown
* address comment
* remove comment
* add url
* keep the location
* remove space
* add unit test for getServerErrorFromUnknown
* improve