Skip to content

Commit

Permalink
lint
Browse files Browse the repository at this point in the history
  • Loading branch information
wheresrhys committed Aug 30, 2018
1 parent 6e84cbd commit bb93527
Showing 1 changed file with 2 additions and 4 deletions.
6 changes: 2 additions & 4 deletions src/lib/response-builder.js
Original file line number Diff line number Diff line change
Expand Up @@ -97,10 +97,9 @@ e.g. {"body": {"status: "registered"}}`);
// convert to json if we need to
if (
this.getOption('sendAsJson') &&
this.shorthandResponse.body != null &&
this.shorthandResponse.body != null && //eslint-disable-line
typeof body === 'object'
) {
//eslint-disable-line
body = JSON.stringify(body);
if (!this.opts.headers.has('Content-Type')) {
this.opts.headers.set('Content-Type', 'application/json');
Expand All @@ -120,8 +119,7 @@ e.g. {"body": {"status: "registered"}}`);
// Response object (on the client this done automatically)
if (this.stream) {
const s = new this.stream.Readable();
if (body != null) {
//eslint-disable-line
if (body != null) { //eslint-disable-line
s.push(body, 'utf-8');
}
s.push(null);
Expand Down

0 comments on commit bb93527

Please sign in to comment.