fix(http): convert objects passed to requests into a string (#10124)
This remove a breaking change introduced with commit #e7a8e2757b06d572f614f53b648d2fd75df370d2 where json objects passed to requests were not converted into string. BREAKING CHANGE: The behavior in this commit is the same as before PR 7260 : the objects sent with the request are converted to a string, therefore there is no need for the user to take care of the serialization. Fixes #10073
This commit is contained in:

committed by
Jeff Cross

parent
3f08efa35d
commit
83bc5c97ef
@ -128,7 +128,7 @@ export class Request extends Body {
|
||||
getBody(): any {
|
||||
switch (this.contentType) {
|
||||
case ContentType.JSON:
|
||||
return this.json();
|
||||
return this.text();
|
||||
case ContentType.FORM:
|
||||
return this.text();
|
||||
case ContentType.FORM_DATA:
|
||||
|
Reference in New Issue
Block a user