chore: disable dart for HTTP package

BREAKING CHANGE

Stop supporting http module in Dart. This is because Dart has a
well developed http package which should be used by Dart
customers instead.
This commit is contained in:
Misko Hevery
2015-08-12 13:03:28 -07:00
parent 38945955ab
commit 284dc67076
15 changed files with 2137 additions and 1968 deletions

View File

@ -8,7 +8,7 @@ import {
Location,
RouteParams
} from 'angular2/router';
import {Http, Response} from 'http/http';
import * as db from './data';
import {ObservableWrapper, PromiseWrapper} from 'angular2/src/facade/async';
import {ListWrapper} from 'angular2/src/facade/collection';
import {isPresent} from 'angular2/src/facade/lang';
@ -59,12 +59,9 @@ class InboxRecord {
@Injectable()
class DbService {
constructor(public http: Http) {}
getData() {
var p = PromiseWrapper.completer();
ObservableWrapper.subscribe<Response>(this.http.get('./db.json'),
(resp) => { p.resolve(resp.json()); });
p.resolve(db.data);
return p.promise;
}