class ViewModel::ActiveRecord::AbstractCollectionUpdate::Parser
def parse(value)
def parse(value) case value when Array replace_update_type.new(parse_contents(value)) when Hash ViewModel::Schemas.verify_schema!(functional_update_schema, value) functional_updates = value[ACTIONS_ATTRIBUTE].map { |action| parse_action(action) } functional_update_type.new(functional_updates) else raise ViewModel::DeserializationError::InvalidSyntax.new( "Could not parse non-array value for collection association '#{association_data}'", blame_reference) end end