Sha256: 083ad9c82f771b7996d61d5dcd329f9398afff14867d80f5f8205e3b595d620e

Contents?: true

Size: 253 Bytes

Versions: 37

Compression:

Stored size: 253 Bytes

Contents

require 'rest-core/middleware/error_detector'

class RestCore::ErrorDetectorHttp < RestCore::ErrorDetector
  def initialize app, detector=nil
    super(app, detector ||
               lambda{ |env| (env[RESPONSE_STATUS] || 200) / 100 >= 4 })
  end
end

Version data entries

37 entries across 37 versions & 1 rubygems

Version Path
rest-core-3.6.0 lib/rest-core/middleware/error_detector_http.rb
rest-core-3.5.92 lib/rest-core/middleware/error_detector_http.rb
rest-core-3.5.91 lib/rest-core/middleware/error_detector_http.rb
rest-core-3.5.9 lib/rest-core/middleware/error_detector_http.rb
rest-core-3.5.8 lib/rest-core/middleware/error_detector_http.rb
rest-core-3.5.7 lib/rest-core/middleware/error_detector_http.rb
rest-core-3.5.6 lib/rest-core/middleware/error_detector_http.rb
rest-core-3.5.5 lib/rest-core/middleware/error_detector_http.rb
rest-core-3.5.4 lib/rest-core/middleware/error_detector_http.rb
rest-core-3.5.3 lib/rest-core/middleware/error_detector_http.rb
rest-core-3.5.2 lib/rest-core/middleware/error_detector_http.rb
rest-core-3.5.1 lib/rest-core/middleware/error_detector_http.rb
rest-core-3.5.0 lib/rest-core/middleware/error_detector_http.rb
rest-core-3.4.1 lib/rest-core/middleware/error_detector_http.rb
rest-core-3.4.0 lib/rest-core/middleware/error_detector_http.rb
rest-core-3.3.3 lib/rest-core/middleware/error_detector_http.rb
rest-core-3.3.2 lib/rest-core/middleware/error_detector_http.rb
rest-core-3.3.1 lib/rest-core/middleware/error_detector_http.rb
rest-core-3.3.0 lib/rest-core/middleware/error_detector_http.rb
rest-core-3.2.0 lib/rest-core/middleware/error_detector_http.rb