Module: Shrine::Plugins::MetadataAttributes

Defined in:
lib/shrine/plugins/metadata_attributes.rb

Overview

Documentation can be found on shrinerb.com/docs/plugins/metadata_attributes

Defined Under Namespace

Modules: AttacherClassMethods, AttacherMethods

Class Method Summary collapse

Class Method Details

.configure(uploader, **opts) ⇒ Object


11
12
13
14
# File 'lib/shrine/plugins/metadata_attributes.rb', line 11

def self.configure(uploader, **opts)
  uploader.opts[:metadata_attributes] ||= {}
  uploader.opts[:metadata_attributes].merge!(opts)
end

.load_dependencies(uploader) ⇒ Object


7
8
9
# File 'lib/shrine/plugins/metadata_attributes.rb', line 7

def self.load_dependencies(uploader, *)
  uploader.plugin :entity
end