Class: Railspress::ContentImportService
- Inherits:
-
Object
- Object
- Railspress::ContentImportService
- Defined in:
- app/services/railspress/content_import_service.rb
Defined Under Namespace
Classes: Result
Constant Summary collapse
- MAX_ZIP_SIZE =
50.megabytes
- MAX_ENTRIES =
500- SUPPORTED_IMAGE_TYPES =
%w[.jpg .jpeg .png .gif .webp].freeze
Instance Method Summary collapse
- #call ⇒ Object
-
#initialize(zip_file) ⇒ ContentImportService
constructor
A new instance of ContentImportService.
Constructor Details
#initialize(zip_file) ⇒ ContentImportService
Returns a new instance of ContentImportService.
23 24 25 26 27 28 29 30 |
# File 'app/services/railspress/content_import_service.rb', line 23 def initialize(zip_file) @zip_file = zip_file @created = 0 @updated = 0 @restored = 0 @errors = [] @extract_dir = nil end |