Revert "fix(http): Update types for TypeScript nullability support"

This reverts commit c36ec9bf60.

Broke in G3.
This commit is contained in:
Tobias Bosch
2017-04-17 09:48:11 -07:00
parent ea8ffc9841
commit 268884296a
18 changed files with 128 additions and 138 deletions

View File

@ -75,7 +75,7 @@ export class Request extends Body {
super();
// TODO: assert that url is present
const url = requestOptions.url;
this.url = requestOptions.url !;
this.url = requestOptions.url;
if (requestOptions.params) {
const params = requestOptions.params.toString();
if (params.length > 0) {
@ -88,13 +88,13 @@ export class Request extends Body {
}
}
this._body = requestOptions.body;
this.method = normalizeMethodName(requestOptions.method !);
this.method = normalizeMethodName(requestOptions.method);
// TODO(jeffbcross): implement behavior
// Defaults to 'omit', consistent with browser
this.headers = new Headers(requestOptions.headers);
this.contentType = this.detectContentType();
this.withCredentials = requestOptions.withCredentials !;
this.responseType = requestOptions.responseType !;
this.withCredentials = requestOptions.withCredentials;
this.responseType = requestOptions.responseType;
}
/**