# class Sprockets::Rails::QuietAssets

### Public Class Methods

new(app) click to toggle source

    # File lib/sprockets/rails/quiet_assets.rb, line 4
    def initialize(app)
      @app = app
      @assets_regex = %r(\A/{0,2}#{::Rails.application.config.assets.prefix})
    end

### Public Instance Methods

call(env) click to toggle source

    # File lib/sprockets/rails/quiet_assets.rb, line 9
    def call(env)
      if env['PATH_INFO'] =~ @assets_regex
        ::Rails.logger.silence { @app.call(env) }
      else
        @app.call(env)
      end
    end