cal.com icon indicating copy to clipboard operation
cal.com copied to clipboard

[CAL-925] fix: add null check for userSchedule.availability

Open ShaneMaglangit opened this issue 2 years ago • 2 comments

What does this PR do?

Fixes #6708

This issue seems to appear when the user does not have any availability created.

  • Does not happen when using any of the pre-created accounts, even if all availability are removed.

Environment: Production

Type of change

  • [x] Bug fix (non-breaking change which fixes an issue)
  • [ ] Chore (refactoring code, technical debt, workflow improvements)
  • [ ] New feature (non-breaking change which adds functionality)
  • [ ] Breaking change (fix or feature that would cause existing functionality to not work as expected)
  • [ ] This change requires a documentation update

How should this be tested?

  • [ ] Test A
  • [ ] Test B

Checklist

  • I haven't commented my code, particularly in hard-to-understand areas
  • I haven't added tests that prove my fix is effective or that my feature works

ShaneMaglangit avatar Feb 11 '23 08:02 ShaneMaglangit

The latest updates on your projects. Learn more about Vercel for Git ↗︎

1 Ignored Deployment
Name Status Preview Comments Updated
ui ⬜️ Ignored (Inspect) Feb 11, 2023 at 8:54AM (UTC)

vercel[bot] avatar Feb 11 '23 08:02 vercel[bot]

@ShaneMaglangit is attempting to deploy a commit to the cal Team on Vercel.

A member of the Team first needs to authorize it.

vercel[bot] avatar Feb 11 '23 08:02 vercel[bot]

Thank you for your contribution! I added a FIXME so we will come back to this later to handle the situation with no availability better; but this fixes the hard crash 👍

emrysal avatar Feb 13 '23 11:02 emrysal