Exception: Sinatra::ServerError

Inherits:
RuntimeError
  • Object
show all
Defined in:
lib/sinatra/compat.rb

Overview

The ServerError exception is deprecated. Any exception is considered an internal server error.

Instance Method Summary collapse

Constructor Details

#initialize(*args, &block) ⇒ ServerError

Returns a new instance of ServerError.



57
58
59
60
# File 'lib/sinatra/compat.rb', line 57

def initialize(*args, &block)
  sinatra_warn 'Sinatra::ServerError is deprecated;',
    'use another exception, error, or Kernel#fail instead.'
end

Instance Method Details

#codeObject



61
# File 'lib/sinatra/compat.rb', line 61

def code ; 500 ; end