class ActiveStorage::Blob

def create_and_upload!(key: nil, io:, filename:, content_type: nil, metadata: nil, service_name: nil, identify: true, record: nil)

automatic content type inference.
When providing a content type, pass identify: false to bypass
be saved before the upload begins to prevent the upload clobbering another due to key collisions.
the given io to the service. The blob instance is going to
Creates a new blob instance and then uploads the contents of
def create_and_upload!(key: nil, io:, filename:, content_type: nil, metadata: nil, service_name: nil, identify: true, record: nil)
  create_after_unfurling!(key: key, io: io, filename: filename, content_type: content_type, metadata: metadata, service_name: service_name, identify: identify).tap do |blob|
    blob.upload_without_unfurling(io)
  end
end