Class: WebSystem::ServerErrorRequest

Inherits:
Request show all
Defined in:
lib/web_system/sub/request/requests/server_error_request.rb

Class Method Summary collapse

Methods inherited from Liza::Controller

color, inherited, on_connected

Methods inherited from Liza::Unit

const_missing, division, part, system, #system, test_class

Class Method Details

.call(env) ⇒ Object



3
4
5
6
7
8
9
10
11
12
13
14
15
# File 'lib/web_system/sub/request/requests/server_error_request.rb', line 3

def self.call env
  status = 500

  headers = {
    "Framework" => "Liza #{Lizarb::VERSION}"
  }

  e = env["LIZA_ERROR"]

  body = "Server Error #{status} - #{e.class} - #{e.message}"

  [status, headers, [body]]
end