Class: Array

Inherits:
Object
  • Object
show all
Defined in:
lib/cancan_strong_parameters/controller.rb

Instance Method Summary collapse

Instance Method Details

#attributizedObject

Attributizes each element in an array



169
170
171
172
173
174
175
176
# File 'lib/cancan_strong_parameters/controller.rb', line 169

def attributized
  Array.new.tap do |a|
    self.each do |v|
      v = v.attributized if v.is_a?(Hash)
      a << v
    end
  end
end