class Sentry::Span

def set_http_status(status_code)

Parameters:
  • status_code (String) -- example: "500".
def set_http_status(status_code)
  status_code = status_code.to_i
  set_data("status_code", status_code)
  status =
    if status_code >= 200 && status_code < 299
      "ok"
    else
      STATUS_MAP[status_code]
    end
  set_status(status)
end