Method: Muina::Maybe::None#map_none
- Defined in:
- lib/muina/maybe/none.rb
#map_none { ... } ⇒ Maybe<yield>, self
If instance is of the Some variant, it returns itself; if instance is of the Muina::Maybe::None variant it runs the block and returns a new Some instance containing the return value of the block.
96 97 98 |
# File 'lib/muina/maybe/none.rb', line 96 def map_none(&_blk) Maybe.return yield end |