method
upload
v5.2.3 -
Show latest stable
- Class:
ActiveStorage::Service::AzureStorageService
upload(key, io, checksum: nil, **)public
No documentation available.
# File activestorage/lib/active_storage/service/azure_storage_service.rb, line 20
def upload(key, io, checksum: nil, **)
instrument :upload, key: key, checksum: checksum do
begin
blobs.create_block_blob(container, key, IO.try_convert(io) || io, content_md5: checksum)
rescue Azure::Core::Http::HTTPError
raise ActiveStorage::IntegrityError
end
end
end