Class: Decidim::DataPortabilityUploader

Inherits:
CarrierWave::Uploader::Base
  • Object
show all
Defined in:
app/uploaders/decidim/data_portability_uploader.rb

Overview

This class deals with saving data portability Zip Files to App

Instance Method Summary collapse

Instance Method Details

#store_dirObject

Override the directory where uploaded files will be stored. def store_dir

default_path = "tmp/data-portability/"
File.join(Rails.root, default_path)

end



12
13
14
15
16
17
18
# File 'app/uploaders/decidim/data_portability_uploader.rb', line 12

def store_dir
  default_path = "tmp/data-portability/"

  return File.join(Decidim.base_uploads_path, default_path) if Decidim.base_uploads_path.present?

  default_path
end