class Restforce::Concerns::BatchAPI::Subrequests

def update(sobject, attrs)

def update(sobject, attrs)
  id = attrs.fetch(attrs.keys.find { |k, v| k.to_s.casecmp?('id') }, nil)
  raise ArgumentError, 'Id field missing from attrs.' unless id
  attrs_without_id = attrs.reject { |k, v| k.to_s.casecmp?('id') }
  requests << {
    method: 'PATCH',
    url: batch_api_path("#{sobject}/#{id}"),
    richInput: attrs_without_id
  }
end