Sha256: 0b0a3b8c74faa3d7f99ddc331c5542f4303760e3175c807e0f01a620f5b2da25

Contents?: true

Size: 776 Bytes

Versions: 75

Compression:

Stored size: 776 Bytes

Contents

# frozen_string_literal: true

# -*- ruby encoding: utf-8 -*-

require 'logger'

##
module MIME
  ##
  class Types
    class << self
      # Configure the MIME::Types logger. This defaults to an instance of a
      # logger that passes messages (unformatted) through to Kernel#warn.
      attr_accessor :logger
    end

    class WarnLogger < ::Logger #:nodoc:
      class WarnLogDevice < ::Logger::LogDevice #:nodoc:
        def initialize(*)
        end

        def write(m)
          Kernel.warn(m)
        end

        def close
        end
      end

      def initialize(_one, _two = nil, _three = nil)
        super nil
        @logdev = WarnLogDevice.new
        @formatter = ->(_s, _d, _p, m) { m }
      end
    end

    self.logger = WarnLogger.new(nil)
  end
end

Version data entries

75 entries across 41 versions & 8 rubygems

Version Path
paynow_sdk-1.1.0 vendor/cache/ruby/2.7.0/gems/mime-types-3.3.1/lib/mime/types/logger.rb
paynow_sdk-1.1.0 vendor/bundle/ruby/2.7.0/gems/paynow_sdk-1.0.9/vendor/cache/ruby/2.7.0/gems/paynow_sdk-1.0.0/vendor/cache/ruby/2.7.0/gems/mime-types-3.3.1/lib/mime/types/logger.rb
paynow_sdk-1.1.0 vendor/bundle/ruby/2.7.0/gems/paynow_sdk-1.0.9/vendor/cache/ruby/2.7.0/gems/mime-types-3.3.1/lib/mime/types/logger.rb
paynow_sdk-1.1.0 vendor/bundle/ruby/2.7.0/gems/mime-types-3.3.1/lib/mime/types/logger.rb
paynow_sdk-1.0.9 vendor/cache/ruby/2.7.0/gems/mime-types-3.3.1/lib/mime/types/logger.rb
paynow_sdk-1.0.9 vendor/cache/ruby/2.7.0/gems/paynow_sdk-1.0.0/vendor/cache/ruby/2.7.0/gems/mime-types-3.3.1/lib/mime/types/logger.rb
paynow_sdk-1.0.9 vendor/bundle/ruby/2.7.0/gems/mime-types-3.3.1/lib/mime/types/logger.rb
paynow_sdk-1.0.8 vendor/cache/ruby/2.7.0/gems/mime-types-3.3.1/lib/mime/types/logger.rb
paynow_sdk-1.0.8 vendor/bundle/ruby/2.7.0/gems/mime-types-3.3.1/lib/mime/types/logger.rb
paynow_sdk-1.0.8 vendor/cache/ruby/2.7.0/gems/paynow_sdk-1.0.0/vendor/cache/ruby/2.7.0/gems/mime-types-3.3.1/lib/mime/types/logger.rb
vagrant-unbundled-2.2.10.0 vendor/bundle/ruby/2.7.0/gems/mime-types-3.3.1/lib/mime/types/logger.rb
paynow_sdk-1.0.7 vendor/cache/ruby/2.7.0/gems/paynow_sdk-1.0.0/vendor/cache/ruby/2.7.0/gems/mime-types-3.3.1/lib/mime/types/logger.rb
paynow_sdk-1.0.7 vendor/cache/ruby/2.7.0/gems/mime-types-3.3.1/lib/mime/types/logger.rb
paynow_sdk-1.0.6 vendor/cache/ruby/2.7.0/gems/paynow_sdk-1.0.0/vendor/cache/ruby/2.7.0/gems/mime-types-3.3.1/lib/mime/types/logger.rb
paynow_sdk-1.0.6 vendor/cache/ruby/2.7.0/gems/mime-types-3.3.1/lib/mime/types/logger.rb
paynow_sdk-1.0.5 vendor/cache/ruby/2.7.0/gems/paynow_sdk-1.0.0/vendor/cache/ruby/2.7.0/gems/mime-types-3.3.1/lib/mime/types/logger.rb
paynow_sdk-1.0.5 vendor/cache/ruby/2.7.0/gems/mime-types-3.3.1/lib/mime/types/logger.rb
paynow_sdk-1.0.4 vendor/cache/ruby/2.7.0/gems/paynow_sdk-1.0.0/vendor/cache/ruby/2.7.0/gems/mime-types-3.3.1/lib/mime/types/logger.rb
paynow_sdk-1.0.4 vendor/cache/ruby/2.7.0/gems/mime-types-3.3.1/lib/mime/types/logger.rb
paynow_sdk-1.0.3 vendor/cache/ruby/2.7.0/gems/paynow_sdk-1.0.0/vendor/cache/ruby/2.7.0/gems/mime-types-3.3.1/lib/mime/types/logger.rb