class Array
Public Instance Methods
to_options_hash()
click to toggle source
# File lib/social_engine/core_ext/array.rb, line 2 def to_options_hash hash = {} self.each do |element| if element.is_a? Symbol hash[element] = {} elsif element.is_a? Hash hash[element.keys[0]] = element.values[0] end end hash end