@pioneer-platform/thor-network 8.1.32 → 8.1.33

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.
Files changed (2) hide show
  1. package/lib/index.js +3 -7
  2. package/package.json +1 -1
package/lib/index.js CHANGED
@@ -176,12 +176,12 @@ var broadcast_transaction = function (tx) {
176
176
  case 3:
177
177
  result2 = _a.sent();
178
178
  log.debug(tag, '** Broadcast ** REMOTE: result: ', result2.data);
179
- if (result2.data.txhash)
179
+ if (result2 && result2.data && result2.data.txhash)
180
180
  output.txid = result2.data.txhash;
181
181
  //verify success
182
182
  if (result2.data.raw_log) {
183
183
  logSend = result2.data.raw_log;
184
- log.debug(tag, "logSend: ", logSend);
184
+ log.info(tag, "logSend: ", logSend);
185
185
  output.success = false;
186
186
  output.error = logSend;
187
187
  }
@@ -202,11 +202,7 @@ var broadcast_transaction = function (tx) {
202
202
  output.success = false;
203
203
  output.error = e_2.response.data.error;
204
204
  return [3 /*break*/, 5];
205
- case 5:
206
- if (output.txid) {
207
- output.success = true;
208
- }
209
- return [2 /*return*/, output];
205
+ case 5: return [2 /*return*/, output];
210
206
  case 6:
211
207
  e_3 = _a.sent();
212
208
  console.error(tag, "throw error: ", e_3);
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@pioneer-platform/thor-network",
3
- "version": "8.1.32",
3
+ "version": "8.1.33",
4
4
  "main": "./lib/index.js",
5
5
  "types": "./lib/index.d.ts",
6
6
  "scripts": {