Method: Rack::Utils.status_code

Defined in:
lib/rack/utils.rb

.status_code(status) ⇒ Object



654
655
656
657
658
659
660
# File 'lib/rack/utils.rb', line 654

def status_code(status)
  if status.is_a?(Symbol)
    SYMBOL_TO_STATUS_CODE[status] || 500
  else
    status.to_i
  end
end