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

request: Make transformer optional in mapNotNull #775

Closed
jnorkus opened this issue Jan 22, 2025 · 2 comments
Closed

request: Make transformer optional in mapNotNull #775

jnorkus opened this issue Jan 22, 2025 · 2 comments
Assignees

Comments

@jnorkus
Copy link

jnorkus commented Jan 22, 2025

Often I find myself using mapNotNull for the only purpose of filtering out nulls. So it would be nice to use it like mapNotNull() instead of mapNotNull((x) => x).

@hoc081098
Copy link
Collaborator

hoc081098 commented Jan 22, 2025

Often I find myself using mapNotNull for the only purpose of filtering out nulls. So it would be nice to use it like mapNotNull() instead of mapNotNull((x) => x).

There is whereNotNull that fits your case.

@jnorkus
Copy link
Author

jnorkus commented Jan 22, 2025

Often I find myself using mapNotNull for the only purpose of filtering out nulls. So it would be nice to use it like mapNotNull() instead of mapNotNull((x) => x).

There is whereNotNull that fits your case.

Somehow I missed that one, that's exactly what I need. Thanks!

@jnorkus jnorkus closed this as completed Jan 22, 2025
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

No branches or pull requests

2 participants