Hi! Is there a more Arrow-ish way to achieve this?...
# arrow
l
Hi! Is there a more Arrow-ish way to achieve this?
Copy code
fun <A, B> Either<A, B>?.f(): Either<A, B?> = this ?: null.right()
s
Hey @Lucas Rango, No, there is nothing special functionality for this in Arrow Core since we’ve always felt that
?:
is easier to understand for most people.