Method: CloudTempfile::Storage#upload_file
- Defined in:
- lib/cloud_tempfile/storage.rb
#upload_file(f, body, options = {}) ⇒ Fog::Storage::File
This action will upload a Fog::Storage::File to the specified directory
31 32 33 34 35 36 37 38 |
# File 'lib/cloud_tempfile/storage.rb', line 31 def upload_file(f, body, ={}) file = init_fog_file(f, body, ) if self.config.enabled? return directory().files.create( file ) else return local_file(f, body, ) end end |