Response.redirect constructor

Response.redirect(
  1. String url, {
  2. int status = 302,
})

Creates a redirect response to the given url with an optional status.

Implementation

Response.redirect(String url, {int status = 302})
    : statusCode = status,
      body = null,
      headers = _CaseInsensitiveMap({'location': url}),
      _cookies = [];