@eluvio/elv-client-js 4.0.75 → 4.0.77

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 (36) hide show
  1. package/dist/ElvClient-min.js +18 -10
  2. package/dist/ElvClient-node-min.js +18 -10
  3. package/dist/ElvFrameClient-min.js +9 -9
  4. package/dist/ElvPermissionsClient-min.js +10 -10
  5. package/dist/ElvWalletClient-min.js +18 -10
  6. package/dist/ElvWalletClient-node-min.js +18 -10
  7. package/dist/src/AuthorizationClient.js +18 -12
  8. package/dist/src/Crypto.js +2 -2
  9. package/dist/src/ElvClient.js +111 -76
  10. package/dist/src/EthClient.js +2 -2
  11. package/dist/src/FrameClient.js +4 -4
  12. package/dist/src/PermissionsClient.js +2 -2
  13. package/dist/src/Utils.js +6 -5
  14. package/dist/src/abr_profiles/abr_profile_live_drm.js +1621 -0
  15. package/dist/src/abr_profiles/abr_profile_live_to_vod.js +1599 -0
  16. package/dist/src/client/ABRPublishing.js +2 -2
  17. package/dist/src/client/AccessGroups.js +19 -20
  18. package/dist/src/client/ContentAccess.js +2 -2
  19. package/dist/src/client/ContentManagement.js +3 -3
  20. package/dist/src/client/Contracts.js +235 -203
  21. package/dist/src/client/Files.js +2 -2
  22. package/dist/src/client/LiveConf.js +1 -1
  23. package/dist/src/client/LiveStream.js +1157 -1153
  24. package/dist/src/client/NFT.js +2 -2
  25. package/dist/src/contracts/v3b/BaseAccessControlGroup.js +1704 -0
  26. package/dist/src/walletClient/ClientMethods.js +423 -280
  27. package/dist/src/walletClient/Profile.js +2 -2
  28. package/dist/src/walletClient/Utils.js +7 -3
  29. package/dist/src/walletClient/index.js +124 -44
  30. package/package.json +2 -1
  31. package/src/FrameClient.js +3 -0
  32. package/src/abr_profiles/abr_profile_live_drm.js +1907 -0
  33. package/src/abr_profiles/abr_profile_live_to_vod.js +1885 -0
  34. package/src/client/LiveConf.js +1 -1
  35. package/src/client/LiveStream.js +809 -936
  36. package/src/walletClient/index.js +1 -1
@@ -2,8 +2,8 @@ var _defineProperty = require("@babel/runtime/helpers/defineProperty");
2
2
  var _typeof = require("@babel/runtime/helpers/typeof");
3
3
  var _regeneratorRuntime = require("@babel/runtime/regenerator");
4
4
  var _asyncToGenerator = require("@babel/runtime/helpers/asyncToGenerator");
5
- function ownKeys(object, enumerableOnly) { var keys = Object.keys(object); if (Object.getOwnPropertySymbols) { var symbols = Object.getOwnPropertySymbols(object); enumerableOnly && (symbols = symbols.filter(function (sym) { return Object.getOwnPropertyDescriptor(object, sym).enumerable; })), keys.push.apply(keys, symbols); } return keys; }
6
- function _objectSpread(target) { for (var i = 1; i < arguments.length; i++) { var source = null != arguments[i] ? arguments[i] : {}; i % 2 ? ownKeys(Object(source), !0).forEach(function (key) { _defineProperty(target, key, source[key]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(target, Object.getOwnPropertyDescriptors(source)) : ownKeys(Object(source)).forEach(function (key) { Object.defineProperty(target, key, Object.getOwnPropertyDescriptor(source, key)); }); } return target; }
5
+ function ownKeys(e, r) { var t = Object.keys(e); if (Object.getOwnPropertySymbols) { var o = Object.getOwnPropertySymbols(e); r && (o = o.filter(function (r) { return Object.getOwnPropertyDescriptor(e, r).enumerable; })), t.push.apply(t, o); } return t; }
6
+ function _objectSpread(e) { for (var r = 1; r < arguments.length; r++) { var t = null != arguments[r] ? arguments[r] : {}; r % 2 ? ownKeys(Object(t), !0).forEach(function (r) { _defineProperty(e, r, t[r]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(t)) : ownKeys(Object(t)).forEach(function (r) { Object.defineProperty(e, r, Object.getOwnPropertyDescriptor(t, r)); }); } return e; }
7
7
  /**
8
8
  * Methods for deploying and interacting with contracts
9
9
  *
@@ -95,6 +95,38 @@ exports.ContractAbi = /*#__PURE__*/function () {
95
95
  };
96
96
  }();
97
97
 
98
+ /**
99
+ * Retrieve the ABI, access type, and whether V3 is used for a given contract via its address or a Fabric ID.
100
+ *
101
+ * @methodGroup Contracts
102
+ * @namedParams
103
+ * @param {string=} id - The Fabric ID of the contract
104
+ * @param {string=} address - The address of the contract
105
+ *
106
+ * @return {Promise<Object>} - The ABI, access type, and isV3 for the given contract
107
+ */
108
+ exports.ContractInfo = /*#__PURE__*/function () {
109
+ var _ref6 = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee3(_ref5) {
110
+ var id, address;
111
+ return _regeneratorRuntime.wrap(function _callee3$(_context3) {
112
+ while (1) switch (_context3.prev = _context3.next) {
113
+ case 0:
114
+ id = _ref5.id, address = _ref5.address;
115
+ return _context3.abrupt("return", this.authClient.ContractInfo({
116
+ id: id,
117
+ address: address
118
+ }));
119
+ case 2:
120
+ case "end":
121
+ return _context3.stop();
122
+ }
123
+ }, _callee3, this);
124
+ }));
125
+ return function (_x3) {
126
+ return _ref6.apply(this, arguments);
127
+ };
128
+ }();
129
+
98
130
  /**
99
131
  * Format the arguments to be used for the specified method of the contract
100
132
  *
@@ -106,10 +138,10 @@ exports.ContractAbi = /*#__PURE__*/function () {
106
138
  *
107
139
  * @returns {Array<string>} - List of formatted arguments
108
140
  */
109
- exports.FormatContractArguments = function (_ref5) {
110
- var abi = _ref5.abi,
111
- methodName = _ref5.methodName,
112
- args = _ref5.args;
141
+ exports.FormatContractArguments = function (_ref7) {
142
+ var abi = _ref7.abi,
143
+ methodName = _ref7.methodName,
144
+ args = _ref7.args;
113
145
  return this.ethClient.FormatContractArguments({
114
146
  abi: abi,
115
147
  methodName: methodName,
@@ -130,13 +162,13 @@ exports.FormatContractArguments = function (_ref5) {
130
162
  * @returns {Promise<Object>} - Response containing the deployed contract address and the transaction hash of the deployment
131
163
  */
132
164
  exports.DeployContract = /*#__PURE__*/function () {
133
- var _ref7 = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee3(_ref6) {
134
- var abi, bytecode, constructorArgs, _ref6$overrides, overrides;
135
- return _regeneratorRuntime.wrap(function _callee3$(_context3) {
136
- while (1) switch (_context3.prev = _context3.next) {
165
+ var _ref9 = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee4(_ref8) {
166
+ var abi, bytecode, constructorArgs, _ref8$overrides, overrides;
167
+ return _regeneratorRuntime.wrap(function _callee4$(_context4) {
168
+ while (1) switch (_context4.prev = _context4.next) {
137
169
  case 0:
138
- abi = _ref6.abi, bytecode = _ref6.bytecode, constructorArgs = _ref6.constructorArgs, _ref6$overrides = _ref6.overrides, overrides = _ref6$overrides === void 0 ? {} : _ref6$overrides;
139
- _context3.next = 3;
170
+ abi = _ref8.abi, bytecode = _ref8.bytecode, constructorArgs = _ref8.constructorArgs, _ref8$overrides = _ref8.overrides, overrides = _ref8$overrides === void 0 ? {} : _ref8$overrides;
171
+ _context4.next = 3;
140
172
  return this.ethClient.DeployContract({
141
173
  abi: abi,
142
174
  bytecode: bytecode,
@@ -145,15 +177,15 @@ exports.DeployContract = /*#__PURE__*/function () {
145
177
  signer: this.signer
146
178
  });
147
179
  case 3:
148
- return _context3.abrupt("return", _context3.sent);
180
+ return _context4.abrupt("return", _context4.sent);
149
181
  case 4:
150
182
  case "end":
151
- return _context3.stop();
183
+ return _context4.stop();
152
184
  }
153
- }, _callee3, this);
185
+ }, _callee4, this);
154
186
  }));
155
- return function (_x3) {
156
- return _ref7.apply(this, arguments);
187
+ return function (_x4) {
188
+ return _ref9.apply(this, arguments);
157
189
  };
158
190
  }();
159
191
 
@@ -172,34 +204,34 @@ exports.DeployContract = /*#__PURE__*/function () {
172
204
  * @returns {Promise<Array<Array<Object>>>} - List of blocks, in ascending order by block number, each containing a list of the events in the block.
173
205
  */
174
206
  exports.ContractEvents = /*#__PURE__*/function () {
175
- var _ref9 = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee4(_ref8) {
176
- var contractAddress, abi, _ref8$fromBlock, fromBlock, toBlock, _ref8$count, count, topics, _ref8$includeTransact, includeTransaction, blocks;
177
- return _regeneratorRuntime.wrap(function _callee4$(_context4) {
178
- while (1) switch (_context4.prev = _context4.next) {
207
+ var _ref11 = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee5(_ref10) {
208
+ var contractAddress, abi, _ref10$fromBlock, fromBlock, toBlock, _ref10$count, count, topics, _ref10$includeTransac, includeTransaction, blocks;
209
+ return _regeneratorRuntime.wrap(function _callee5$(_context5) {
210
+ while (1) switch (_context5.prev = _context5.next) {
179
211
  case 0:
180
- contractAddress = _ref8.contractAddress, abi = _ref8.abi, _ref8$fromBlock = _ref8.fromBlock, fromBlock = _ref8$fromBlock === void 0 ? 0 : _ref8$fromBlock, toBlock = _ref8.toBlock, _ref8$count = _ref8.count, count = _ref8$count === void 0 ? 1000 : _ref8$count, topics = _ref8.topics, _ref8$includeTransact = _ref8.includeTransaction, includeTransaction = _ref8$includeTransact === void 0 ? false : _ref8$includeTransact;
212
+ contractAddress = _ref10.contractAddress, abi = _ref10.abi, _ref10$fromBlock = _ref10.fromBlock, fromBlock = _ref10$fromBlock === void 0 ? 0 : _ref10$fromBlock, toBlock = _ref10.toBlock, _ref10$count = _ref10.count, count = _ref10$count === void 0 ? 1000 : _ref10$count, topics = _ref10.topics, _ref10$includeTransac = _ref10.includeTransaction, includeTransaction = _ref10$includeTransac === void 0 ? false : _ref10$includeTransac;
181
213
  contractAddress = ValidateAddress(contractAddress);
182
214
  if (abi) {
183
- _context4.next = 6;
215
+ _context5.next = 6;
184
216
  break;
185
217
  }
186
- _context4.next = 5;
218
+ _context5.next = 5;
187
219
  return this.ContractAbi({
188
220
  contractAddress: contractAddress
189
221
  });
190
222
  case 5:
191
- abi = _context4.sent;
223
+ abi = _context5.sent;
192
224
  case 6:
193
- _context4.next = 8;
225
+ _context5.next = 8;
194
226
  return this.FormatBlockNumbers({
195
227
  fromBlock: fromBlock,
196
228
  toBlock: toBlock,
197
229
  count: count
198
230
  });
199
231
  case 8:
200
- blocks = _context4.sent;
232
+ blocks = _context5.sent;
201
233
  this.Log("Querying contract events ".concat(contractAddress, " - Blocks ").concat(blocks.fromBlock, " to ").concat(blocks.toBlock));
202
- _context4.next = 12;
234
+ _context5.next = 12;
203
235
  return this.ethClient.ContractEvents({
204
236
  contractAddress: contractAddress,
205
237
  abi: abi,
@@ -209,15 +241,15 @@ exports.ContractEvents = /*#__PURE__*/function () {
209
241
  includeTransaction: includeTransaction
210
242
  });
211
243
  case 12:
212
- return _context4.abrupt("return", _context4.sent);
244
+ return _context5.abrupt("return", _context5.sent);
213
245
  case 13:
214
246
  case "end":
215
- return _context4.stop();
247
+ return _context5.stop();
216
248
  }
217
- }, _callee4, this);
249
+ }, _callee5, this);
218
250
  }));
219
- return function (_x4) {
220
- return _ref9.apply(this, arguments);
251
+ return function (_x5) {
252
+ return _ref11.apply(this, arguments);
221
253
  };
222
254
  }();
223
255
 
@@ -240,12 +272,12 @@ exports.ContractEvents = /*#__PURE__*/function () {
240
272
  * @returns {Promise<*>} - Response containing information about the transaction
241
273
  */
242
274
  exports.CallContractMethod = /*#__PURE__*/function () {
243
- var _ref11 = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee5(_ref10) {
244
- var contractAddress, abi, methodName, _ref10$methodArgs, methodArgs, value, _ref10$overrides, overrides, _ref10$formatArgument, formatArguments, _ref10$cacheContract, cacheContract, _ref10$overrideCached, overrideCachedContract;
245
- return _regeneratorRuntime.wrap(function _callee5$(_context5) {
246
- while (1) switch (_context5.prev = _context5.next) {
275
+ var _ref13 = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee6(_ref12) {
276
+ var contractAddress, abi, methodName, _ref12$methodArgs, methodArgs, value, _ref12$overrides, overrides, _ref12$formatArgument, formatArguments, _ref12$cacheContract, cacheContract, _ref12$overrideCached, overrideCachedContract;
277
+ return _regeneratorRuntime.wrap(function _callee6$(_context6) {
278
+ while (1) switch (_context6.prev = _context6.next) {
247
279
  case 0:
248
- contractAddress = _ref10.contractAddress, abi = _ref10.abi, methodName = _ref10.methodName, _ref10$methodArgs = _ref10.methodArgs, methodArgs = _ref10$methodArgs === void 0 ? [] : _ref10$methodArgs, value = _ref10.value, _ref10$overrides = _ref10.overrides, overrides = _ref10$overrides === void 0 ? {} : _ref10$overrides, _ref10$formatArgument = _ref10.formatArguments, formatArguments = _ref10$formatArgument === void 0 ? true : _ref10$formatArgument, _ref10$cacheContract = _ref10.cacheContract, cacheContract = _ref10$cacheContract === void 0 ? true : _ref10$cacheContract, _ref10$overrideCached = _ref10.overrideCachedContract, overrideCachedContract = _ref10$overrideCached === void 0 ? false : _ref10$overrideCached;
280
+ contractAddress = _ref12.contractAddress, abi = _ref12.abi, methodName = _ref12.methodName, _ref12$methodArgs = _ref12.methodArgs, methodArgs = _ref12$methodArgs === void 0 ? [] : _ref12$methodArgs, value = _ref12.value, _ref12$overrides = _ref12.overrides, overrides = _ref12$overrides === void 0 ? {} : _ref12$overrides, _ref12$formatArgument = _ref12.formatArguments, formatArguments = _ref12$formatArgument === void 0 ? true : _ref12$formatArgument, _ref12$cacheContract = _ref12.cacheContract, cacheContract = _ref12$cacheContract === void 0 ? true : _ref12$cacheContract, _ref12$overrideCached = _ref12.overrideCachedContract, overrideCachedContract = _ref12$overrideCached === void 0 ? false : _ref12$overrideCached;
249
281
  contractAddress = ValidateAddress(contractAddress);
250
282
 
251
283
  // Delete cached visibility value if it is being changed
@@ -254,17 +286,17 @@ exports.CallContractMethod = /*#__PURE__*/function () {
254
286
  delete this.visibilityInfo[contractAddress];
255
287
  }
256
288
  if (abi) {
257
- _context5.next = 8;
289
+ _context6.next = 8;
258
290
  break;
259
291
  }
260
- _context5.next = 7;
292
+ _context6.next = 7;
261
293
  return this.ContractAbi({
262
294
  contractAddress: contractAddress
263
295
  });
264
296
  case 7:
265
- abi = _context5.sent;
297
+ abi = _context6.sent;
266
298
  case 8:
267
- _context5.next = 10;
299
+ _context6.next = 10;
268
300
  return this.ethClient.CallContractMethod({
269
301
  contractAddress: contractAddress,
270
302
  abi: abi,
@@ -277,15 +309,15 @@ exports.CallContractMethod = /*#__PURE__*/function () {
277
309
  overrideCachedContract: overrideCachedContract
278
310
  });
279
311
  case 10:
280
- return _context5.abrupt("return", _context5.sent);
312
+ return _context6.abrupt("return", _context6.sent);
281
313
  case 11:
282
314
  case "end":
283
- return _context5.stop();
315
+ return _context6.stop();
284
316
  }
285
- }, _callee5, this);
317
+ }, _callee6, this);
286
318
  }));
287
- return function (_x5) {
288
- return _ref11.apply(this, arguments);
319
+ return function (_x6) {
320
+ return _ref13.apply(this, arguments);
289
321
  };
290
322
  }();
291
323
 
@@ -311,12 +343,12 @@ exports.CallContractMethod = /*#__PURE__*/function () {
311
343
  * the resulting event(s)
312
344
  */
313
345
  exports.CallContractMethodAndWait = /*#__PURE__*/function () {
314
- var _ref13 = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee6(_ref12) {
315
- var contractAddress, abi, methodName, methodArgs, value, _ref12$overrides, overrides, _ref12$formatArgument, formatArguments, _ref12$cacheContract, cacheContract, _ref12$overrideCached, overrideCachedContract;
316
- return _regeneratorRuntime.wrap(function _callee6$(_context6) {
317
- while (1) switch (_context6.prev = _context6.next) {
346
+ var _ref15 = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee7(_ref14) {
347
+ var contractAddress, abi, methodName, methodArgs, value, _ref14$overrides, overrides, _ref14$formatArgument, formatArguments, _ref14$cacheContract, cacheContract, _ref14$overrideCached, overrideCachedContract;
348
+ return _regeneratorRuntime.wrap(function _callee7$(_context7) {
349
+ while (1) switch (_context7.prev = _context7.next) {
318
350
  case 0:
319
- contractAddress = _ref12.contractAddress, abi = _ref12.abi, methodName = _ref12.methodName, methodArgs = _ref12.methodArgs, value = _ref12.value, _ref12$overrides = _ref12.overrides, overrides = _ref12$overrides === void 0 ? {} : _ref12$overrides, _ref12$formatArgument = _ref12.formatArguments, formatArguments = _ref12$formatArgument === void 0 ? true : _ref12$formatArgument, _ref12$cacheContract = _ref12.cacheContract, cacheContract = _ref12$cacheContract === void 0 ? true : _ref12$cacheContract, _ref12$overrideCached = _ref12.overrideCachedContract, overrideCachedContract = _ref12$overrideCached === void 0 ? false : _ref12$overrideCached;
351
+ contractAddress = _ref14.contractAddress, abi = _ref14.abi, methodName = _ref14.methodName, methodArgs = _ref14.methodArgs, value = _ref14.value, _ref14$overrides = _ref14.overrides, overrides = _ref14$overrides === void 0 ? {} : _ref14$overrides, _ref14$formatArgument = _ref14.formatArguments, formatArguments = _ref14$formatArgument === void 0 ? true : _ref14$formatArgument, _ref14$cacheContract = _ref14.cacheContract, cacheContract = _ref14$cacheContract === void 0 ? true : _ref14$cacheContract, _ref14$overrideCached = _ref14.overrideCachedContract, overrideCachedContract = _ref14$overrideCached === void 0 ? false : _ref14$overrideCached;
320
352
  contractAddress = ValidateAddress(contractAddress);
321
353
 
322
354
  // Delete cached visibility value if it is being changed
@@ -325,17 +357,17 @@ exports.CallContractMethodAndWait = /*#__PURE__*/function () {
325
357
  delete this.visibilityInfo[contractAddress];
326
358
  }
327
359
  if (abi) {
328
- _context6.next = 8;
360
+ _context7.next = 8;
329
361
  break;
330
362
  }
331
- _context6.next = 7;
363
+ _context7.next = 7;
332
364
  return this.ContractAbi({
333
365
  contractAddress: contractAddress
334
366
  });
335
367
  case 7:
336
- abi = _context6.sent;
368
+ abi = _context7.sent;
337
369
  case 8:
338
- _context6.next = 10;
370
+ _context7.next = 10;
339
371
  return this.ethClient.CallContractMethodAndWait({
340
372
  contractAddress: contractAddress,
341
373
  abi: abi,
@@ -348,15 +380,15 @@ exports.CallContractMethodAndWait = /*#__PURE__*/function () {
348
380
  overrideCachedContract: overrideCachedContract
349
381
  });
350
382
  case 10:
351
- return _context6.abrupt("return", _context6.sent);
383
+ return _context7.abrupt("return", _context7.sent);
352
384
  case 11:
353
385
  case "end":
354
- return _context6.stop();
386
+ return _context7.stop();
355
387
  }
356
- }, _callee6, this);
388
+ }, _callee7, this);
357
389
  }));
358
- return function (_x6) {
359
- return _ref13.apply(this, arguments);
390
+ return function (_x7) {
391
+ return _ref15.apply(this, arguments);
360
392
  };
361
393
  }();
362
394
 
@@ -371,45 +403,45 @@ exports.CallContractMethodAndWait = /*#__PURE__*/function () {
371
403
  * @return {Promise<Object|string>}
372
404
  */
373
405
  exports.ContractMetadata = /*#__PURE__*/function () {
374
- var _ref15 = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee7(_ref14) {
406
+ var _ref17 = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee8(_ref16) {
375
407
  var contractAddress, metadataKey, metadata, data;
376
- return _regeneratorRuntime.wrap(function _callee7$(_context7) {
377
- while (1) switch (_context7.prev = _context7.next) {
408
+ return _regeneratorRuntime.wrap(function _callee8$(_context8) {
409
+ while (1) switch (_context8.prev = _context8.next) {
378
410
  case 0:
379
- contractAddress = _ref14.contractAddress, metadataKey = _ref14.metadataKey;
411
+ contractAddress = _ref16.contractAddress, metadataKey = _ref16.metadataKey;
380
412
  ValidatePresence("contractAddress", contractAddress);
381
413
  ValidatePresence("metadataKey", metadataKey);
382
- _context7.prev = 3;
383
- _context7.next = 6;
414
+ _context8.prev = 3;
415
+ _context8.next = 6;
384
416
  return this.CallContractMethod({
385
417
  contractAddress: contractAddress,
386
418
  methodName: "getMeta",
387
419
  methodArgs: [metadataKey]
388
420
  });
389
421
  case 6:
390
- metadata = _context7.sent;
422
+ metadata = _context8.sent;
391
423
  data = Buffer.from((metadata || "").replace("0x", ""), "hex").toString("utf-8");
392
- _context7.prev = 8;
393
- return _context7.abrupt("return", JSON.parse(data));
424
+ _context8.prev = 8;
425
+ return _context8.abrupt("return", JSON.parse(data));
394
426
  case 12:
395
- _context7.prev = 12;
396
- _context7.t0 = _context7["catch"](8);
397
- return _context7.abrupt("return", data);
427
+ _context8.prev = 12;
428
+ _context8.t0 = _context8["catch"](8);
429
+ return _context8.abrupt("return", data);
398
430
  case 15:
399
- _context7.next = 20;
431
+ _context8.next = 20;
400
432
  break;
401
433
  case 17:
402
- _context7.prev = 17;
403
- _context7.t1 = _context7["catch"](3);
404
- return _context7.abrupt("return", "");
434
+ _context8.prev = 17;
435
+ _context8.t1 = _context8["catch"](3);
436
+ return _context8.abrupt("return", "");
405
437
  case 20:
406
438
  case "end":
407
- return _context7.stop();
439
+ return _context8.stop();
408
440
  }
409
- }, _callee7, this, [[3, 17], [8, 12]]);
441
+ }, _callee8, this, [[3, 17], [8, 12]]);
410
442
  }));
411
- return function (_x7) {
412
- return _ref15.apply(this, arguments);
443
+ return function (_x8) {
444
+ return _ref17.apply(this, arguments);
413
445
  };
414
446
  }();
415
447
 
@@ -423,32 +455,32 @@ exports.ContractMetadata = /*#__PURE__*/function () {
423
455
  * @param {string} metadata
424
456
  */
425
457
  exports.MergeContractMetadata = /*#__PURE__*/function () {
426
- var _ref17 = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee8(_ref16) {
458
+ var _ref19 = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee9(_ref18) {
427
459
  var contractAddress, metadataKey, metadata, existingMetadata;
428
- return _regeneratorRuntime.wrap(function _callee8$(_context8) {
429
- while (1) switch (_context8.prev = _context8.next) {
460
+ return _regeneratorRuntime.wrap(function _callee9$(_context9) {
461
+ while (1) switch (_context9.prev = _context9.next) {
430
462
  case 0:
431
- contractAddress = _ref16.contractAddress, metadataKey = _ref16.metadataKey, metadata = _ref16.metadata;
463
+ contractAddress = _ref18.contractAddress, metadataKey = _ref18.metadataKey, metadata = _ref18.metadata;
432
464
  ValidatePresence("contractAddress", contractAddress);
433
465
  ValidatePresence("metadataKey", metadataKey);
434
- _context8.next = 5;
466
+ _context9.next = 5;
435
467
  return this.ContractMetadata({
436
468
  contractAddress: contractAddress,
437
469
  metadataKey: metadataKey
438
470
  });
439
471
  case 5:
440
- _context8.t0 = _context8.sent;
441
- if (_context8.t0) {
442
- _context8.next = 8;
472
+ _context9.t0 = _context9.sent;
473
+ if (_context9.t0) {
474
+ _context9.next = 8;
443
475
  break;
444
476
  }
445
- _context8.t0 = {};
477
+ _context9.t0 = {};
446
478
  case 8:
447
- existingMetadata = _context8.t0;
479
+ existingMetadata = _context9.t0;
448
480
  if (_typeof(existingMetadata) === "object") {
449
481
  metadata = _objectSpread(_objectSpread({}, existingMetadata), metadata);
450
482
  }
451
- _context8.next = 12;
483
+ _context9.next = 12;
452
484
  return this.CallContractMethodAndWait({
453
485
  contractAddress: contractAddress,
454
486
  methodName: "putMeta",
@@ -456,12 +488,12 @@ exports.MergeContractMetadata = /*#__PURE__*/function () {
456
488
  });
457
489
  case 12:
458
490
  case "end":
459
- return _context8.stop();
491
+ return _context9.stop();
460
492
  }
461
- }, _callee8, this);
493
+ }, _callee9, this);
462
494
  }));
463
- return function (_x8) {
464
- return _ref17.apply(this, arguments);
495
+ return function (_x9) {
496
+ return _ref19.apply(this, arguments);
465
497
  };
466
498
  }();
467
499
 
@@ -475,15 +507,15 @@ exports.MergeContractMetadata = /*#__PURE__*/function () {
475
507
  * @param {string|Object} metadata - The metadata to insert
476
508
  */
477
509
  exports.ReplaceContractMetadata = /*#__PURE__*/function () {
478
- var _ref19 = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee9(_ref18) {
510
+ var _ref21 = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee10(_ref20) {
479
511
  var contractAddress, metadataKey, metadata;
480
- return _regeneratorRuntime.wrap(function _callee9$(_context9) {
481
- while (1) switch (_context9.prev = _context9.next) {
512
+ return _regeneratorRuntime.wrap(function _callee10$(_context10) {
513
+ while (1) switch (_context10.prev = _context10.next) {
482
514
  case 0:
483
- contractAddress = _ref18.contractAddress, metadataKey = _ref18.metadataKey, metadata = _ref18.metadata;
515
+ contractAddress = _ref20.contractAddress, metadataKey = _ref20.metadataKey, metadata = _ref20.metadata;
484
516
  ValidatePresence("contractAddress", contractAddress);
485
517
  ValidatePresence("metadataKey", metadataKey);
486
- _context9.next = 5;
518
+ _context10.next = 5;
487
519
  return this.CallContractMethodAndWait({
488
520
  contractAddress: contractAddress,
489
521
  methodName: "putMeta",
@@ -491,12 +523,12 @@ exports.ReplaceContractMetadata = /*#__PURE__*/function () {
491
523
  });
492
524
  case 5:
493
525
  case "end":
494
- return _context9.stop();
526
+ return _context10.stop();
495
527
  }
496
- }, _callee9, this);
528
+ }, _callee10, this);
497
529
  }));
498
- return function (_x9) {
499
- return _ref19.apply(this, arguments);
530
+ return function (_x10) {
531
+ return _ref21.apply(this, arguments);
500
532
  };
501
533
  }();
502
534
 
@@ -512,12 +544,12 @@ exports.ReplaceContractMetadata = /*#__PURE__*/function () {
512
544
  * @returns {Promise<string> | undefined} - If the object has a custom contract, this will return the address of the custom contract
513
545
  */
514
546
  exports.CustomContractAddress = /*#__PURE__*/function () {
515
- var _ref21 = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee10(_ref20) {
547
+ var _ref23 = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee11(_ref22) {
516
548
  var libraryId, objectId, versionHash, abi, customContractAddress;
517
- return _regeneratorRuntime.wrap(function _callee10$(_context10) {
518
- while (1) switch (_context10.prev = _context10.next) {
549
+ return _regeneratorRuntime.wrap(function _callee11$(_context11) {
550
+ while (1) switch (_context11.prev = _context11.next) {
519
551
  case 0:
520
- libraryId = _ref20.libraryId, objectId = _ref20.objectId, versionHash = _ref20.versionHash;
552
+ libraryId = _ref22.libraryId, objectId = _ref22.objectId, versionHash = _ref22.versionHash;
521
553
  ValidateParameters({
522
554
  libraryId: libraryId,
523
555
  objectId: objectId,
@@ -527,19 +559,19 @@ exports.CustomContractAddress = /*#__PURE__*/function () {
527
559
  objectId = this.utils.DecodeVersionHash(versionHash).objectId;
528
560
  }
529
561
  if (!(libraryId === this.contentSpaceLibraryId || this.utils.EqualHash(libraryId, objectId))) {
530
- _context10.next = 5;
562
+ _context11.next = 5;
531
563
  break;
532
564
  }
533
- return _context10.abrupt("return");
565
+ return _context11.abrupt("return");
534
566
  case 5:
535
567
  this.Log("Retrieving custom contract address: ".concat(objectId));
536
- _context10.next = 8;
568
+ _context11.next = 8;
537
569
  return this.ContractAbi({
538
570
  id: objectId
539
571
  });
540
572
  case 8:
541
- abi = _context10.sent;
542
- _context10.next = 11;
573
+ abi = _context11.sent;
574
+ _context11.next = 11;
543
575
  return this.ethClient.CallContractMethod({
544
576
  contractAddress: this.utils.HashToAddress(objectId),
545
577
  abi: abi,
@@ -547,22 +579,22 @@ exports.CustomContractAddress = /*#__PURE__*/function () {
547
579
  methodArgs: []
548
580
  });
549
581
  case 11:
550
- customContractAddress = _context10.sent;
582
+ customContractAddress = _context11.sent;
551
583
  if (!(customContractAddress === this.utils.nullAddress)) {
552
- _context10.next = 14;
584
+ _context11.next = 14;
553
585
  break;
554
586
  }
555
- return _context10.abrupt("return");
587
+ return _context11.abrupt("return");
556
588
  case 14:
557
- return _context10.abrupt("return", this.utils.FormatAddress(customContractAddress));
589
+ return _context11.abrupt("return", this.utils.FormatAddress(customContractAddress));
558
590
  case 15:
559
591
  case "end":
560
- return _context10.stop();
592
+ return _context11.stop();
561
593
  }
562
- }, _callee10, this);
594
+ }, _callee11, this);
563
595
  }));
564
- return function (_x10) {
565
- return _ref21.apply(this, arguments);
596
+ return function (_x11) {
597
+ return _ref23.apply(this, arguments);
566
598
  };
567
599
  }();
568
600
 
@@ -585,12 +617,12 @@ exports.CustomContractAddress = /*#__PURE__*/function () {
585
617
  * @returns {Promise<Object>} - Result transaction of calling the setCustomContract method on the content object contract
586
618
  */
587
619
  exports.SetCustomContentContract = /*#__PURE__*/function () {
588
- var _ref23 = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee11(_ref22) {
589
- var libraryId, objectId, customContractAddress, name, description, abi, factoryAbi, _ref22$overrides, overrides, setResult, writeToken;
590
- return _regeneratorRuntime.wrap(function _callee11$(_context11) {
591
- while (1) switch (_context11.prev = _context11.next) {
620
+ var _ref25 = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee12(_ref24) {
621
+ var libraryId, objectId, customContractAddress, name, description, abi, factoryAbi, _ref24$overrides, overrides, setResult, writeToken;
622
+ return _regeneratorRuntime.wrap(function _callee12$(_context12) {
623
+ while (1) switch (_context12.prev = _context12.next) {
592
624
  case 0:
593
- libraryId = _ref22.libraryId, objectId = _ref22.objectId, customContractAddress = _ref22.customContractAddress, name = _ref22.name, description = _ref22.description, abi = _ref22.abi, factoryAbi = _ref22.factoryAbi, _ref22$overrides = _ref22.overrides, overrides = _ref22$overrides === void 0 ? {} : _ref22$overrides;
625
+ libraryId = _ref24.libraryId, objectId = _ref24.objectId, customContractAddress = _ref24.customContractAddress, name = _ref24.name, description = _ref24.description, abi = _ref24.abi, factoryAbi = _ref24.factoryAbi, _ref24$overrides = _ref24.overrides, overrides = _ref24$overrides === void 0 ? {} : _ref24$overrides;
594
626
  ValidateParameters({
595
627
  libraryId: libraryId,
596
628
  objectId: objectId
@@ -598,7 +630,7 @@ exports.SetCustomContentContract = /*#__PURE__*/function () {
598
630
  customContractAddress = ValidateAddress(customContractAddress);
599
631
  customContractAddress = this.utils.FormatAddress(customContractAddress);
600
632
  this.Log("Setting custom contract address: ".concat(objectId, " ").concat(customContractAddress));
601
- _context11.next = 7;
633
+ _context12.next = 7;
602
634
  return this.ethClient.SetCustomContentContract({
603
635
  contentContractAddress: this.utils.HashToAddress(objectId),
604
636
  customContractAddress: customContractAddress,
@@ -606,15 +638,15 @@ exports.SetCustomContentContract = /*#__PURE__*/function () {
606
638
  signer: this.signer
607
639
  });
608
640
  case 7:
609
- setResult = _context11.sent;
610
- _context11.next = 10;
641
+ setResult = _context12.sent;
642
+ _context12.next = 10;
611
643
  return this.EditContentObject({
612
644
  libraryId: libraryId,
613
645
  objectId: objectId
614
646
  });
615
647
  case 10:
616
- writeToken = _context11.sent.write_token;
617
- _context11.next = 13;
648
+ writeToken = _context12.sent.write_token;
649
+ _context12.next = 13;
618
650
  return this.ReplaceMetadata({
619
651
  libraryId: libraryId,
620
652
  objectId: objectId,
@@ -629,7 +661,7 @@ exports.SetCustomContentContract = /*#__PURE__*/function () {
629
661
  }
630
662
  });
631
663
  case 13:
632
- _context11.next = 15;
664
+ _context12.next = 15;
633
665
  return this.FinalizeContentObject({
634
666
  libraryId: libraryId,
635
667
  objectId: objectId,
@@ -637,15 +669,15 @@ exports.SetCustomContentContract = /*#__PURE__*/function () {
637
669
  commitMessage: "Set custom contract"
638
670
  });
639
671
  case 15:
640
- return _context11.abrupt("return", setResult);
672
+ return _context12.abrupt("return", setResult);
641
673
  case 16:
642
674
  case "end":
643
- return _context11.stop();
675
+ return _context12.stop();
644
676
  }
645
- }, _callee11, this);
677
+ }, _callee12, this);
646
678
  }));
647
- return function (_x11) {
648
- return _ref23.apply(this, arguments);
679
+ return function (_x12) {
680
+ return _ref25.apply(this, arguments);
649
681
  };
650
682
  }();
651
683
 
@@ -664,10 +696,10 @@ exports.SetCustomContentContract = /*#__PURE__*/function () {
664
696
  *
665
697
  * @returns {Promise<Object>} - The parsed event log from the event
666
698
  */
667
- exports.ExtractEventFromLogs = function (_ref24) {
668
- var abi = _ref24.abi,
669
- event = _ref24.event,
670
- eventName = _ref24.eventName;
699
+ exports.ExtractEventFromLogs = function (_ref26) {
700
+ var abi = _ref26.abi,
701
+ event = _ref26.event,
702
+ eventName = _ref26.eventName;
671
703
  return this.ethClient.ExtractEventFromLogs({
672
704
  abi: abi,
673
705
  event: event,
@@ -689,11 +721,11 @@ exports.ExtractEventFromLogs = function (_ref24) {
689
721
  *
690
722
  * @returns {Promise<string>} The value extracted from the event
691
723
  */
692
- exports.ExtractValueFromEvent = function (_ref25) {
693
- var abi = _ref25.abi,
694
- event = _ref25.event,
695
- eventName = _ref25.eventName,
696
- eventValue = _ref25.eventValue;
724
+ exports.ExtractValueFromEvent = function (_ref27) {
725
+ var abi = _ref27.abi,
726
+ event = _ref27.event,
727
+ eventName = _ref27.eventName,
728
+ eventValue = _ref27.eventValue;
697
729
  var eventLog = this.ethClient.ExtractEventFromLogs({
698
730
  abi: abi,
699
731
  event: event,
@@ -703,16 +735,16 @@ exports.ExtractValueFromEvent = function (_ref25) {
703
735
  return eventLog ? eventLog.args[eventValue] : undefined;
704
736
  };
705
737
  exports.FormatBlockNumbers = /*#__PURE__*/function () {
706
- var _ref27 = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee12(_ref26) {
707
- var fromBlock, toBlock, _ref26$count, count, latestBlock;
708
- return _regeneratorRuntime.wrap(function _callee12$(_context12) {
709
- while (1) switch (_context12.prev = _context12.next) {
738
+ var _ref29 = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee13(_ref28) {
739
+ var fromBlock, toBlock, _ref28$count, count, latestBlock;
740
+ return _regeneratorRuntime.wrap(function _callee13$(_context13) {
741
+ while (1) switch (_context13.prev = _context13.next) {
710
742
  case 0:
711
- fromBlock = _ref26.fromBlock, toBlock = _ref26.toBlock, _ref26$count = _ref26.count, count = _ref26$count === void 0 ? 10 : _ref26$count;
712
- _context12.next = 3;
743
+ fromBlock = _ref28.fromBlock, toBlock = _ref28.toBlock, _ref28$count = _ref28.count, count = _ref28$count === void 0 ? 10 : _ref28$count;
744
+ _context13.next = 3;
713
745
  return this.BlockNumber();
714
746
  case 3:
715
- latestBlock = _context12.sent;
747
+ latestBlock = _context13.sent;
716
748
  if (!toBlock) {
717
749
  if (!fromBlock) {
718
750
  toBlock = latestBlock;
@@ -731,18 +763,18 @@ exports.FormatBlockNumbers = /*#__PURE__*/function () {
731
763
  if (fromBlock < 0) {
732
764
  fromBlock = 0;
733
765
  }
734
- return _context12.abrupt("return", {
766
+ return _context13.abrupt("return", {
735
767
  fromBlock: fromBlock,
736
768
  toBlock: toBlock
737
769
  });
738
770
  case 8:
739
771
  case "end":
740
- return _context12.stop();
772
+ return _context13.stop();
741
773
  }
742
- }, _callee12, this);
774
+ }, _callee13, this);
743
775
  }));
744
- return function (_x12) {
745
- return _ref27.apply(this, arguments);
776
+ return function (_x13) {
777
+ return _ref29.apply(this, arguments);
746
778
  };
747
779
  }();
748
780
 
@@ -760,42 +792,42 @@ exports.FormatBlockNumbers = /*#__PURE__*/function () {
760
792
  * Note: This requires two extra network calls per transaction, so it should not be used for very large ranges
761
793
  * @returns {Promise<Array<Array<Object>>>} - List of blocks, in ascending order by block number, each containing a list of the events in the block.
762
794
  */
763
- exports.Events = /*#__PURE__*/_asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee13() {
764
- var _ref29,
795
+ exports.Events = /*#__PURE__*/_asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee14() {
796
+ var _ref31,
765
797
  toBlock,
766
798
  fromBlock,
767
- _ref29$count,
799
+ _ref31$count,
768
800
  count,
769
- _ref29$includeTransac,
801
+ _ref31$includeTransac,
770
802
  includeTransaction,
771
803
  blocks,
772
- _args13 = arguments;
773
- return _regeneratorRuntime.wrap(function _callee13$(_context13) {
774
- while (1) switch (_context13.prev = _context13.next) {
804
+ _args14 = arguments;
805
+ return _regeneratorRuntime.wrap(function _callee14$(_context14) {
806
+ while (1) switch (_context14.prev = _context14.next) {
775
807
  case 0:
776
- _ref29 = _args13.length > 0 && _args13[0] !== undefined ? _args13[0] : {}, toBlock = _ref29.toBlock, fromBlock = _ref29.fromBlock, _ref29$count = _ref29.count, count = _ref29$count === void 0 ? 10 : _ref29$count, _ref29$includeTransac = _ref29.includeTransaction, includeTransaction = _ref29$includeTransac === void 0 ? false : _ref29$includeTransac;
777
- _context13.next = 3;
808
+ _ref31 = _args14.length > 0 && _args14[0] !== undefined ? _args14[0] : {}, toBlock = _ref31.toBlock, fromBlock = _ref31.fromBlock, _ref31$count = _ref31.count, count = _ref31$count === void 0 ? 10 : _ref31$count, _ref31$includeTransac = _ref31.includeTransaction, includeTransaction = _ref31$includeTransac === void 0 ? false : _ref31$includeTransac;
809
+ _context14.next = 3;
778
810
  return this.FormatBlockNumbers({
779
811
  fromBlock: fromBlock,
780
812
  toBlock: toBlock,
781
813
  count: count
782
814
  });
783
815
  case 3:
784
- blocks = _context13.sent;
816
+ blocks = _context14.sent;
785
817
  this.Log("Querying events - Blocks ".concat(blocks.fromBlock, " to ").concat(blocks.toBlock));
786
- _context13.next = 7;
818
+ _context14.next = 7;
787
819
  return this.ethClient.Events({
788
820
  fromBlock: blocks.fromBlock,
789
821
  toBlock: blocks.toBlock,
790
822
  includeTransaction: includeTransaction
791
823
  });
792
824
  case 7:
793
- return _context13.abrupt("return", _context13.sent);
825
+ return _context14.abrupt("return", _context14.sent);
794
826
  case 8:
795
827
  case "end":
796
- return _context13.stop();
828
+ return _context14.stop();
797
829
  }
798
- }, _callee13, this);
830
+ }, _callee14, this);
799
831
  }));
800
832
 
801
833
  /**
@@ -805,21 +837,21 @@ exports.Events = /*#__PURE__*/_asyncToGenerator( /*#__PURE__*/_regeneratorRuntim
805
837
  *
806
838
  * @returns {Promise<number>} - The latest block number
807
839
  */
808
- exports.BlockNumber = /*#__PURE__*/_asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee14() {
809
- return _regeneratorRuntime.wrap(function _callee14$(_context14) {
810
- while (1) switch (_context14.prev = _context14.next) {
840
+ exports.BlockNumber = /*#__PURE__*/_asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee15() {
841
+ return _regeneratorRuntime.wrap(function _callee15$(_context15) {
842
+ while (1) switch (_context15.prev = _context15.next) {
811
843
  case 0:
812
- _context14.next = 2;
844
+ _context15.next = 2;
813
845
  return this.ethClient.MakeProviderCall({
814
846
  methodName: "getBlockNumber"
815
847
  });
816
848
  case 2:
817
- return _context14.abrupt("return", _context14.sent);
849
+ return _context15.abrupt("return", _context15.sent);
818
850
  case 3:
819
851
  case "end":
820
- return _context14.stop();
852
+ return _context15.stop();
821
853
  }
822
- }, _callee14, this);
854
+ }, _callee15, this);
823
855
  }));
824
856
 
825
857
  /**
@@ -832,29 +864,29 @@ exports.BlockNumber = /*#__PURE__*/_asyncToGenerator( /*#__PURE__*/_regeneratorR
832
864
  * @returns {Promise<string>} - Balance of the account, in ether (as string)
833
865
  */
834
866
  exports.GetBalance = /*#__PURE__*/function () {
835
- var _ref32 = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee15(_ref31) {
867
+ var _ref34 = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee16(_ref33) {
836
868
  var address, balance;
837
- return _regeneratorRuntime.wrap(function _callee15$(_context15) {
838
- while (1) switch (_context15.prev = _context15.next) {
869
+ return _regeneratorRuntime.wrap(function _callee16$(_context16) {
870
+ while (1) switch (_context16.prev = _context16.next) {
839
871
  case 0:
840
- address = _ref31.address;
872
+ address = _ref33.address;
841
873
  address = ValidateAddress(address);
842
- _context15.next = 4;
874
+ _context16.next = 4;
843
875
  return this.ethClient.MakeProviderCall({
844
876
  methodName: "getBalance",
845
877
  args: [address]
846
878
  });
847
879
  case 4:
848
- balance = _context15.sent;
849
- return _context15.abrupt("return", Ethers.utils.formatEther(balance));
880
+ balance = _context16.sent;
881
+ return _context16.abrupt("return", Ethers.utils.formatEther(balance));
850
882
  case 6:
851
883
  case "end":
852
- return _context15.stop();
884
+ return _context16.stop();
853
885
  }
854
- }, _callee15, this);
886
+ }, _callee16, this);
855
887
  }));
856
- return function (_x13) {
857
- return _ref32.apply(this, arguments);
888
+ return function (_x14) {
889
+ return _ref34.apply(this, arguments);
858
890
  };
859
891
  }();
860
892
 
@@ -869,31 +901,31 @@ exports.GetBalance = /*#__PURE__*/function () {
869
901
  * @returns {Promise<Object>} - The transaction receipt
870
902
  */
871
903
  exports.SendFunds = /*#__PURE__*/function () {
872
- var _ref34 = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee16(_ref33) {
904
+ var _ref36 = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee17(_ref35) {
873
905
  var recipient, ether, transaction;
874
- return _regeneratorRuntime.wrap(function _callee16$(_context16) {
875
- while (1) switch (_context16.prev = _context16.next) {
906
+ return _regeneratorRuntime.wrap(function _callee17$(_context17) {
907
+ while (1) switch (_context17.prev = _context17.next) {
876
908
  case 0:
877
- recipient = _ref33.recipient, ether = _ref33.ether;
909
+ recipient = _ref35.recipient, ether = _ref35.ether;
878
910
  recipient = ValidateAddress(recipient);
879
- _context16.next = 4;
911
+ _context17.next = 4;
880
912
  return this.signer.sendTransaction({
881
913
  to: recipient,
882
914
  value: Ethers.utils.parseEther(ether.toString())
883
915
  });
884
916
  case 4:
885
- transaction = _context16.sent;
886
- _context16.next = 7;
917
+ transaction = _context17.sent;
918
+ _context17.next = 7;
887
919
  return transaction.wait();
888
920
  case 7:
889
- return _context16.abrupt("return", _context16.sent);
921
+ return _context17.abrupt("return", _context17.sent);
890
922
  case 8:
891
923
  case "end":
892
- return _context16.stop();
924
+ return _context17.stop();
893
925
  }
894
- }, _callee16, this);
926
+ }, _callee17, this);
895
927
  }));
896
- return function (_x14) {
897
- return _ref34.apply(this, arguments);
928
+ return function (_x15) {
929
+ return _ref36.apply(this, arguments);
898
930
  };
899
931
  }();