| Index: sdk/lib/io/http_impl.dart
|
| diff --git a/sdk/lib/io/http_impl.dart b/sdk/lib/io/http_impl.dart
|
| index 3af4000b2f300237c9b4346b3c006f582f1d6408..3cf6cde93bd2900c1d7b2bf5078f362b4f546004 100644
|
| --- a/sdk/lib/io/http_impl.dart
|
| +++ b/sdk/lib/io/http_impl.dart
|
| @@ -708,6 +708,13 @@ class _HttpResponse extends _HttpOutboundMessage<HttpResponse>
|
| _reasonPhrase = reasonPhrase;
|
| }
|
|
|
| + Future redirect(Uri location, {int status: HttpStatus.MOVED_TEMPORARILY}) {
|
| + if (_headersWritten) throw new StateError("Header already sent");
|
| + statusCode = status;
|
| + headers.set("Location", location.toString());
|
| + return close();
|
| + }
|
| +
|
| Future<Socket> detachSocket() {
|
| if (_headersWritten) throw new StateError("Headers already sent");
|
| deadline = null; // Be sure to stop any deadline.
|
| @@ -1908,7 +1915,7 @@ class _HttpServer extends Stream<HttpRequest> implements HttpServer {
|
| backlog: backlog,
|
| requestClientCertificate: requestClientCertificate)
|
| .then((socket) {
|
| - return new _HttpServer._(socket, true);
|
| + return new _HttpServer._(socket, true);
|
| });
|
| }
|
|
|
|
|