Sha256: e07b452b554431d6fb3fb257913c4fc2c862801ac48d11c4c1dadc5b96bc21ed

Contents?: true

Size: 406 Bytes

Versions: 2

Compression:

Stored size: 406 Bytes

Contents

module DynamicSitemaps
  class Logger
    class << self
      def info(message)
        show message
        Rails.logger.info message
      end

      def warn(message)
        show message
        Rails.logger.warn message
      end

      # Shows the message using puts unless testing.
      def show(message)
        unless Rails.env.test?
          puts message
        end
      end
    end
  end
end

Version data entries

2 entries across 2 versions & 1 rubygems

Version Path
dynamic_sitemaps-2.0.0 lib/dynamic_sitemaps/logger.rb
dynamic_sitemaps-2.0.0.beta2 lib/dynamic_sitemaps/logger.rb