Module: S3Proxy::App::Errors

Defined in:
lib/s3_proxy/app.rb

Class Method Summary collapse

Class Method Details

.forbiddenObject



84
85
86
# File 'lib/s3_proxy/app.rb', line 84

def forbidden
  [403, {'Content-Type' => 'text/plain'}, ["forbidden"]]
end

.method_not_allowedObject



76
77
78
# File 'lib/s3_proxy/app.rb', line 76

def method_not_allowed
  [405, {'Content-Type' => 'text/plain'}, ["method not allowed"]]
end

.not_foundObject



80
81
82
# File 'lib/s3_proxy/app.rb', line 80

def not_found
  [404, {'Content-Type' => 'text/plain'}, ["not found"]]
end

.unknown(code) ⇒ Object



88
89
90
# File 'lib/s3_proxy/app.rb', line 88

def unknown(code)
  [code, {'Content-Type' => 'text/plain'}, ["Error: #{code}"]]
end