Method: Array#mapp

Defined in:
lib/mapp.rb

#mapp(&block) ⇒ Object



4
5
6
7
8
9
10
11
12
# File 'lib/mapp.rb', line 4

def mapp(&block)
  map do |item|
    if item.is_a? Array
      item.mapp(&block)
    else
      block.call(item)
    end
  end
end