chore: enable logical assignment babel plugin (#8416)
This commit is contained in:
parent
c0010d16c6
commit
7f02e9ebb1
1
.babelrc
1
.babelrc
|
|
@ -6,6 +6,7 @@
|
||||||
["@babel/plugin-transform-typescript", { "allowDeclareFields": true } ],
|
["@babel/plugin-transform-typescript", { "allowDeclareFields": true } ],
|
||||||
"@babel/plugin-proposal-export-namespace-from",
|
"@babel/plugin-proposal-export-namespace-from",
|
||||||
"@babel/plugin-proposal-class-properties",
|
"@babel/plugin-proposal-class-properties",
|
||||||
|
"@babel/plugin-proposal-logical-assignment-operators",
|
||||||
"@babel/plugin-proposal-optional-chaining",
|
"@babel/plugin-proposal-optional-chaining",
|
||||||
"@babel/plugin-transform-modules-commonjs"
|
"@babel/plugin-transform-modules-commonjs"
|
||||||
],
|
],
|
||||||
|
|
|
||||||
|
|
@ -272,8 +272,8 @@ export class Route extends ChannelOwner<channels.RouteChannel, channels.RouteIni
|
||||||
let useInterceptedResponseBody;
|
let useInterceptedResponseBody;
|
||||||
let { status: statusOption, headers: headersOption, body: bodyOption } = options;
|
let { status: statusOption, headers: headersOption, body: bodyOption } = options;
|
||||||
if (options._response) {
|
if (options._response) {
|
||||||
statusOption = statusOption || options._response.status();
|
statusOption ||= options._response.status();
|
||||||
headersOption = headersOption || options._response.headers();
|
headersOption ||= options._response.headers();
|
||||||
if (options.body === undefined && options.path === undefined) {
|
if (options.body === undefined && options.path === undefined) {
|
||||||
if (options._response === this._interceptedResponse)
|
if (options._response === this._interceptedResponse)
|
||||||
useInterceptedResponseBody = true;
|
useInterceptedResponseBody = true;
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue