mapMaybe package:pipes

(mapMaybe f) yields Just results of f. Basic laws:
mapMaybe (f >=> g) = mapMaybe f >-> mapMaybe g

mapMaybe (pure @Maybe . f) = mapMaybe (Just . f) = map f

mapMaybe (const Nothing) = drain
As a result of the second law,
mapMaybe return = mapMaybe Just = cat