Sha256: a31c9558bb4c5bb2f598c6ffc29ebc810a197ab19664c7d15880ef3d44d060e3
Contents?: true
Size: 441 Bytes
Versions: 3
Compression:
Stored size: 441 Bytes
Contents
module Scrivito class CmsRestApi module BlobUploader class << self def upload_file(file) upload_permission = CmsRestApi.get('blobs/upload_permission') fields = upload_permission['fields'].merge({file: file}) # Net/HTTP does not support multipart forms RestClient.post(upload_permission['url'], fields) upload_permission['blob'] end end end end end
Version data entries
3 entries across 3 versions & 1 rubygems