Method: AWS::S3::S3Object#delete

Defined in:
lib/aws/s3/s3_object.rb

#delete(options = {}) ⇒ nil

Deletes the object from its S3 bucket.

Parameters:

  • options (Hash) (defaults to: {})
  • [String] (Hash)

    a customizable set of options

Returns:

  • (nil)


159
160
161
162
163
164
# File 'lib/aws/s3/s3_object.rb', line 159

def delete options = {}
  options[:bucket_name] = bucket.name
  options[:key] = key
  client.delete_object(options)
  nil
end