@pioneer-platform/rango-client 8.3.4 → 8.3.6

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 +11 -5
  2. package/package.json +1 -1
package/lib/index.js CHANGED
@@ -106,23 +106,29 @@ var create_transaction = function (id, step, validateBalance, validateFee) {
106
106
  };
107
107
  var get_quote = function (quote) {
108
108
  return __awaiter(this, void 0, void 0, function () {
109
- var tag, output, e_2;
109
+ var tag, output, unsignedTx, e_2;
110
110
  return __generator(this, function (_a) {
111
111
  switch (_a.label) {
112
112
  case 0:
113
113
  tag = TAG + " | get_quote | ";
114
114
  _a.label = 1;
115
115
  case 1:
116
- _a.trys.push([1, 3, , 4]);
116
+ _a.trys.push([1, 4, , 5]);
117
117
  return [4 /*yield*/, rango.getBestRoute(quote)];
118
118
  case 2:
119
119
  output = _a.sent();
120
- return [2 /*return*/, output];
120
+ log.info(tag, "output: ", output);
121
+ return [4 /*yield*/, create_transaction(output.requestId, 1, false, false)];
121
122
  case 3:
123
+ unsignedTx = _a.sent();
124
+ log.info(tag, "unsignedTx: ", unsignedTx);
125
+ output.unsignedTx = unsignedTx;
126
+ return [2 /*return*/, output];
127
+ case 4:
122
128
  e_2 = _a.sent();
123
129
  console.error(tag, "e: ", e_2);
124
- return [3 /*break*/, 4];
125
- case 4: return [2 /*return*/];
130
+ return [3 /*break*/, 5];
131
+ case 5: return [2 /*return*/];
126
132
  }
127
133
  });
128
134
  });
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@pioneer-platform/rango-client",
3
- "version": "8.3.4",
3
+ "version": "8.3.6",
4
4
  "main": "./lib/index.js",
5
5
  "types": "./lib/index.d.ts",
6
6
  "dependencies": {