Sha256: 54af4ce06d362c76536bcc950024a46517f3cf4b0034b9f7ff42a94e6f066c1a

Contents?: true

Size: 416 Bytes

Versions: 4

Compression:

Stored size: 416 Bytes

Contents

module SimpleImages
  module ImageableAdditions
    def self.included(base)
      base.extend ClassMethods
    end

    module ClassMethods
      def has_simple_images
        include SimpleImages::ImageableAdditions::InstanceMethods

        has_many :simple_images, as: :imageable
      end
    end

    module InstanceMethods

    end
  end
end

ActiveRecord::Base.send(:include, SimpleImages::ImageableAdditions)

Version data entries

4 entries across 4 versions & 1 rubygems

Version Path
simple_images-0.0.4 lib/simple_images/imageable_additions.rb
simple_images-0.0.3 lib/simple_images/imageable_additions.rb
simple_images-0.0.2 lib/simple_images/imageable_additions.rb
simple_images-0.0.1 lib/simple_images/imageable_additions.rb