@opentap/runner-client 2.9.0 → 2.9.1-alpha.1.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/lib/BaseClient.js +1 -5
- package/package.json +1 -1
package/lib/BaseClient.js
CHANGED
|
@@ -187,8 +187,7 @@ var BaseClient = /** @class */ (function () {
|
|
|
187
187
|
});
|
|
188
188
|
return resolve(flattenedArray);
|
|
189
189
|
};
|
|
190
|
-
})
|
|
191
|
-
.then(function (byteArray) {
|
|
190
|
+
}).then(function (byteArray) {
|
|
192
191
|
if (byteArray.length === 0) {
|
|
193
192
|
return Promise.resolve(undefined);
|
|
194
193
|
}
|
|
@@ -196,9 +195,6 @@ var BaseClient = /** @class */ (function () {
|
|
|
196
195
|
// If a raw response is requested, we should avoid decoding the bytes.
|
|
197
196
|
var response = (options === null || options === void 0 ? void 0 : options.rawResponse) ? byteArray : jsonCodec.decode(byteArray);
|
|
198
197
|
return _this.isErrorResponse(response) ? Promise.reject(ErrorResponse.fromJS(response)) : Promise.resolve(response);
|
|
199
|
-
})
|
|
200
|
-
.catch(function (err) {
|
|
201
|
-
return Promise.reject(_this.natsErrorHandler(err, subject));
|
|
202
198
|
});
|
|
203
199
|
chunk = getChunk(0);
|
|
204
200
|
this.connection.publish(subject, chunk, opts);
|