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(iif): No longer allow accidental undefined arguments #5829

Merged
merged 1 commit into from
Oct 20, 2020

Conversation

benlesh
Copy link
Member

@benlesh benlesh commented Oct 15, 2020

  • Updates types
  • Ensures that result arguments must be passed
  • Ensures narrower type when conditional result is known to be true, or known to be false.

BREAKING CHANGE: iif will no longer allow result arguments that are undefined. This was a bad call pattern that was likely an error in most cases. If for some reason you are relying on this behavior, simply substitute EMPTY in place of the undefined argument. This ensures that the behavior was intentional and desired, rather than the result of an accidental undefined argument.

- Updates types
- Ensures that result arguments must be passed
- Ensures narrower type when conditional result is known to be `true`, or known to be `false`.

BREAKING CHANGE: `iif` will no longer allow result arguments that are `undefined`. This was a bad call pattern that was likely an error in most cases. If for some reason you are relying on this behavior, simply substitute `EMPTY` in place of the `undefined` argument. This ensures that the behavior was intentional and desired, rather than the result of an accidental `undefined` argument.
@benlesh benlesh force-pushed the fix/iif-no-undefined-arguments branch from 48a307c to b2cdd06 Compare October 15, 2020 20:52
@benlesh benlesh merged commit 23b98b4 into ReactiveX:master Oct 20, 2020
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.

2 participants