Sha256: 92d9ed93de60ff4b42ca0e2fbd891748c4ed0f9ac47bc50f67293fc680d75a14

Contents?: true

Size: 448 Bytes

Versions: 5

Compression:

Stored size: 448 Bytes

Contents

# frozen_string_literal: true

# Handles `Paperclip` attachments on the backend in a delayed process.
module Paperweight
  # Allows configuring certain attributes about how to process attachments.
  class Configuration
    attr_accessor :max_size

    def initialize
      @max_size = 10 * 1024 * 1024
    end
  end

  class << self
    def config
      @config ||= Configuration.new
    end

    def configure
      yield config
    end
  end
end

Version data entries

5 entries across 5 versions & 1 rubygems

Version Path
paperweight-1.1.0 lib/paperweight/configuration.rb
paperweight-1.0.2 lib/paperweight/configuration.rb
paperweight-1.0.1 lib/paperweight/configuration.rb
paperweight-1.0.0 lib/paperweight/configuration.rb
paperweight-0.2.0 lib/paperweight/configuration.rb