Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix calendar availability failing when round_robin is nil #375

Conversation

mrashed-dev
Copy link
Contributor

Description

This PR address the issue where, if round_robin is left as nil, it always yields an error. This is because the Nylas Docs were out of date for the availability endpoint. round_robin is optional, and when omitted, returns collective availability. However, sending null is not valid despite what it says in the documentation. Now, we omit the value from the json payload if the value is nil.

License

I confirm that this contribution is made under the terms of the MIT license and that I have the authority necessary to make this contribution on behalf of its copyright owner.

The availability endpoint only accepts optional params as an omitted value, not as a "null" value.
@mrashed-dev mrashed-dev requested review from a team, quzhi1 and arjunkalburgi and removed request for a team July 26, 2022 18:29
@quzhi1
Copy link

quzhi1 commented Jul 26, 2022

CI is failing

@mrashed-dev
Copy link
Contributor Author

Thanks @quzhi1, CI is fixed now :)

@mrashed-dev mrashed-dev merged commit ce61604 into main Jul 26, 2022
@mrashed-dev mrashed-dev deleted the TSDK-363-nylas-calendar-collection-availability-returns-nylas-invalid-request-when-round-robin-parameter-is-nil-github-issue-373 branch July 26, 2022 18:54
@mrashed-dev mrashed-dev mentioned this pull request Jul 29, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Nylas::CalendarCollection.availability returns Nylas::InvalidRequest when :round_robin parameter is nil
2 participants