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

Typings for find don't include undefined #3969

Closed
cartant opened this issue Jul 28, 2018 · 0 comments · Fixed by severest/retrobot#221
Closed

Typings for find don't include undefined #3969

cartant opened this issue Jul 28, 2018 · 0 comments · Fixed by severest/retrobot#221

Comments

@cartant
Copy link
Collaborator

cartant commented Jul 28, 2018

Bug Report

Current Behavior

The overload signatures for find don't reflect the operator's behaviour.

The return types are OperatorFunction<T, S> and MonoTypeOperatorFunction<T>.

However, the operator will emit undefined if no match is found. See this test.

Possible Solution

The return types should be OperatorFunction<T, S | undefined> and OperatorFunction<T, T | undefined>.

cartant added a commit to cartant/rxjs that referenced this issue Jul 28, 2018
cartant added a commit to cartant/rxjs that referenced this issue Jul 29, 2018
@lock lock bot locked as resolved and limited conversation to collaborators Aug 28, 2018
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant