Class: CurationConcerns::Actors::AttachFilesActor
Overview
Instance Attribute Summary
#next_actor
Instance Method Summary
collapse
#initialize
Instance Method Details
#create(attributes) ⇒ Object
4
5
6
7
8
|
# File 'app/actors/curation_concerns/actors/attach_files_actor.rb', line 4
def create(attributes)
files = [attributes.delete(:files)].flatten.compact
attach_files(files, visibility_attributes(attributes)) &&
next_actor.create(attributes)
end
|
#update(attributes) ⇒ Object
10
11
12
13
14
|
# File 'app/actors/curation_concerns/actors/attach_files_actor.rb', line 10
def update(attributes)
files = [attributes.delete(:files)].flatten.compact
next_actor.update(attributes) &&
attach_files(files, visibility_attributes(attributes))
end
|