roboto-js 1.9.15 → 3.0.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.
@@ -358,11 +358,47 @@ var RbtObject = exports["default"] = /*#__PURE__*/function () {
358
358
  });
359
359
  return clonedObject;
360
360
  }
361
+
362
+ /**
363
+ * Rebuild read_ids/write_ids record meta from iac grant arrays.
364
+ * Keeps denormalized columns in sync with dataJson.iac for delta saves.
365
+ */
366
+ }, {
367
+ key: "_syncIacRecordMeta",
368
+ value: function _syncIacRecordMeta() {
369
+ var iac = _lodash["default"].get(this._data, 'iac');
370
+ if (!iac) return;
371
+ var readIds = new Set();
372
+ var writeIds = new Set();
373
+ if (this.type === '<@iac.user>') {
374
+ writeIds.add(this.id);
375
+ readIds.add(this.id);
376
+ }
377
+ if (iac.creator) {
378
+ writeIds.add(iac.creator);
379
+ readIds.add(iac.creator);
380
+ }
381
+ var collect = function collect(grants, target) {
382
+ if (!grants) return;
383
+ for (var _i = 0, _arr = ['users', 'userGroups', 'organizations', 'userSegments']; _i < _arr.length; _i++) {
384
+ var key = _arr[_i];
385
+ if (Array.isArray(grants[key])) {
386
+ grants[key].forEach(function (id) {
387
+ return target.add(id);
388
+ });
389
+ }
390
+ }
391
+ };
392
+ collect(iac.readGrants, readIds);
393
+ collect(iac.writeGrants, writeIds);
394
+ this._internalData.read_ids = Array.from(readIds).join(',');
395
+ this._internalData.write_ids = Array.from(writeIds).join(',');
396
+ }
361
397
  }, {
362
398
  key: "save",
363
399
  value: function () {
364
400
  var _save = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime().mark(function _callee3() {
365
- var _response$data, _response$data2, record, response;
401
+ var _response$data, _response$data2, iacGrantChange, record, response;
366
402
  return _regeneratorRuntime().wrap(function _callee3$(_context3) {
367
403
  while (1) switch (_context3.prev = _context3.next) {
368
404
  case 0:
@@ -373,28 +409,34 @@ var RbtObject = exports["default"] = /*#__PURE__*/function () {
373
409
  throw new Error('Cannot save object without type');
374
410
  case 2:
375
411
  _context3.prev = 2;
412
+ iacGrantChange = (this.rpcMeta.changes || []).some(function (path) {
413
+ return path.startsWith('iac.readGrants') || path.startsWith('iac.writeGrants');
414
+ });
415
+ if (iacGrantChange) {
416
+ this._syncIacRecordMeta();
417
+ }
376
418
  if (this.rpcMeta.isNew) {
377
419
  record = this.toRecord();
378
420
  } else {
379
421
  record = this.toDeltaRecord();
380
422
  }
381
- _context3.next = 6;
423
+ _context3.next = 8;
382
424
  return this._axios.post('/object_service/saveObject', [record]);
383
- case 6:
425
+ case 8:
384
426
  response = _context3.sent;
385
427
  if (!(response.data.ok === false)) {
386
- _context3.next = 9;
428
+ _context3.next = 11;
387
429
  break;
388
430
  }
389
431
  throw new Error(response.data.message);
390
- case 9:
432
+ case 11:
391
433
  if (!(((_response$data = response.data) === null || _response$data === void 0 ? void 0 : _response$data.result) == 'NO_CHANGES')) {
392
- _context3.next = 12;
434
+ _context3.next = 14;
393
435
  break;
394
436
  }
395
437
  this.rpcMeta.isNew = false;
396
438
  return _context3.abrupt("return", this);
397
- case 12:
439
+ case 14:
398
440
  if ((_response$data2 = response.data) !== null && _response$data2 !== void 0 && _response$data2.newData) {
399
441
  // apply new incoming data
400
442
  this.setData(response.newData);
@@ -404,17 +446,17 @@ var RbtObject = exports["default"] = /*#__PURE__*/function () {
404
446
  this.type = response.data.type;
405
447
  this.rpcMeta.isNew = false;
406
448
  return _context3.abrupt("return", this);
407
- case 20:
408
- _context3.prev = 20;
449
+ case 22:
450
+ _context3.prev = 22;
409
451
  _context3.t0 = _context3["catch"](2);
410
452
  this._error = _context3.t0;
411
453
  //console.log(e.response.data);
412
454
  throw _context3.t0;
413
- case 24:
455
+ case 26:
414
456
  case "end":
415
457
  return _context3.stop();
416
458
  }
417
- }, _callee3, this, [[2, 20]]);
459
+ }, _callee3, this, [[2, 22]]);
418
460
  }));
419
461
  function save() {
420
462
  return _save.apply(this, arguments);
@@ -531,19 +573,20 @@ var RbtObject = exports["default"] = /*#__PURE__*/function () {
531
573
  this.set(groupsPath, _toConsumableArray(new Set([].concat(_toConsumableArray(existingGroups), _toConsumableArray(groupIds)))));
532
574
  }
533
575
  }
576
+ this._syncIacRecordMeta();
534
577
 
535
578
  // Save if requested
536
579
  if (!save) {
537
- _context4.next = 15;
580
+ _context4.next = 16;
538
581
  break;
539
582
  }
540
- _context4.next = 14;
583
+ _context4.next = 15;
541
584
  return this.save();
542
- case 14:
543
- return _context4.abrupt("return", _context4.sent);
544
585
  case 15:
545
- return _context4.abrupt("return", this);
586
+ return _context4.abrupt("return", _context4.sent);
546
587
  case 16:
588
+ return _context4.abrupt("return", this);
589
+ case 17:
547
590
  case "end":
548
591
  return _context4.stop();
549
592
  }
@@ -776,19 +819,20 @@ var RbtObject = exports["default"] = /*#__PURE__*/function () {
776
819
  return !groupIds.includes(id);
777
820
  }));
778
821
  }
822
+ this._syncIacRecordMeta();
779
823
 
780
824
  // Save if requested
781
825
  if (!save) {
782
- _context7.next = 15;
826
+ _context7.next = 16;
783
827
  break;
784
828
  }
785
- _context7.next = 14;
829
+ _context7.next = 15;
786
830
  return this.save();
787
- case 14:
788
- return _context7.abrupt("return", _context7.sent);
789
831
  case 15:
790
- return _context7.abrupt("return", this);
832
+ return _context7.abrupt("return", _context7.sent);
791
833
  case 16:
834
+ return _context7.abrupt("return", this);
835
+ case 17:
792
836
  case "end":
793
837
  return _context7.stop();
794
838
  }
@@ -158,7 +158,7 @@ var RbtUser = exports["default"] = /*#__PURE__*/function () {
158
158
  record = this.toRecord();
159
159
  record.type = '<@iac.user>';
160
160
  _context.next = 6;
161
- return this._axios.post('/user_service/saveUser', [record]);
161
+ return this._axios.post('/api/iac/saveUser', [record]);
162
162
  case 6:
163
163
  response = _context.sent;
164
164
  if (!(response.data.ok === false)) {
@@ -6,5 +6,5 @@ Object.defineProperty(exports, "__esModule", {
6
6
  exports.version = void 0;
7
7
  // Auto-generated version file
8
8
  // DO NOT EDIT - This file is automatically updated from package.cjson
9
- // Version: 1.9.15
10
- var version = exports.version = '1.9.15';
9
+ // Version: 3.0.1
10
+ var version = exports.version = '3.0.1';
package/dist/esm/index.js CHANGED
@@ -478,46 +478,120 @@ var Roboto = /*#__PURE__*/function () {
478
478
  return _confirmUserEmail.apply(this, arguments);
479
479
  }
480
480
  return confirmUserEmail;
481
- }() //
482
- // Organization management
483
- //
481
+ }()
484
482
  }, {
485
- key: "loadCurrentOrganization",
483
+ key: "sendResetEmailViaFlows",
486
484
  value: function () {
487
- var _loadCurrentOrganization = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime().mark(function _callee11() {
488
- var forceReload,
489
- _args11 = arguments;
485
+ var _sendResetEmailViaFlows = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime().mark(function _callee11(email) {
490
486
  return _regeneratorRuntime().wrap(function _callee11$(_context11) {
491
487
  while (1) switch (_context11.prev = _context11.next) {
492
488
  case 0:
493
- forceReload = _args11.length > 0 && _args11[0] !== undefined ? _args11[0] : false;
494
- return _context11.abrupt("return", this.api.loadCurrentOrganization(forceReload));
495
- case 2:
489
+ return _context11.abrupt("return", this.api.sendResetEmailViaFlows(email));
490
+ case 1:
496
491
  case "end":
497
492
  return _context11.stop();
498
493
  }
499
494
  }, _callee11, this);
500
495
  }));
501
- function loadCurrentOrganization() {
502
- return _loadCurrentOrganization.apply(this, arguments);
496
+ function sendResetEmailViaFlows(_x6) {
497
+ return _sendResetEmailViaFlows.apply(this, arguments);
503
498
  }
504
- return loadCurrentOrganization;
499
+ return sendResetEmailViaFlows;
505
500
  }()
506
501
  }, {
507
- key: "switchOrganization",
502
+ key: "sendRegistrationVerificationEmail",
508
503
  value: function () {
509
- var _switchOrganization = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime().mark(function _callee12(orgId) {
504
+ var _sendRegistrationVerificationEmail = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime().mark(function _callee12(email) {
510
505
  return _regeneratorRuntime().wrap(function _callee12$(_context12) {
511
506
  while (1) switch (_context12.prev = _context12.next) {
512
507
  case 0:
513
- return _context12.abrupt("return", this.api.switchOrganization(orgId));
508
+ return _context12.abrupt("return", this.api.sendRegistrationVerificationEmail(email));
514
509
  case 1:
515
510
  case "end":
516
511
  return _context12.stop();
517
512
  }
518
513
  }, _callee12, this);
519
514
  }));
520
- function switchOrganization(_x6) {
515
+ function sendRegistrationVerificationEmail(_x7) {
516
+ return _sendRegistrationVerificationEmail.apply(this, arguments);
517
+ }
518
+ return sendRegistrationVerificationEmail;
519
+ }()
520
+ }, {
521
+ key: "resendRegistrationCode",
522
+ value: function () {
523
+ var _resendRegistrationCode = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime().mark(function _callee13(email) {
524
+ return _regeneratorRuntime().wrap(function _callee13$(_context13) {
525
+ while (1) switch (_context13.prev = _context13.next) {
526
+ case 0:
527
+ return _context13.abrupt("return", this.api.resendRegistrationCode(email));
528
+ case 1:
529
+ case "end":
530
+ return _context13.stop();
531
+ }
532
+ }, _callee13, this);
533
+ }));
534
+ function resendRegistrationCode(_x8) {
535
+ return _resendRegistrationCode.apply(this, arguments);
536
+ }
537
+ return resendRegistrationCode;
538
+ }()
539
+ }, {
540
+ key: "completePasswordReset",
541
+ value: function () {
542
+ var _completePasswordReset = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime().mark(function _callee14(params) {
543
+ return _regeneratorRuntime().wrap(function _callee14$(_context14) {
544
+ while (1) switch (_context14.prev = _context14.next) {
545
+ case 0:
546
+ return _context14.abrupt("return", this.api.completePasswordReset(params));
547
+ case 1:
548
+ case "end":
549
+ return _context14.stop();
550
+ }
551
+ }, _callee14, this);
552
+ }));
553
+ function completePasswordReset(_x9) {
554
+ return _completePasswordReset.apply(this, arguments);
555
+ }
556
+ return completePasswordReset;
557
+ }()
558
+ }, {
559
+ key: "loadCurrentOrganization",
560
+ value: function () {
561
+ var _loadCurrentOrganization = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime().mark(function _callee15() {
562
+ var forceReload,
563
+ _args15 = arguments;
564
+ return _regeneratorRuntime().wrap(function _callee15$(_context15) {
565
+ while (1) switch (_context15.prev = _context15.next) {
566
+ case 0:
567
+ forceReload = _args15.length > 0 && _args15[0] !== undefined ? _args15[0] : false;
568
+ return _context15.abrupt("return", this.api.loadCurrentOrganization(forceReload));
569
+ case 2:
570
+ case "end":
571
+ return _context15.stop();
572
+ }
573
+ }, _callee15, this);
574
+ }));
575
+ function loadCurrentOrganization() {
576
+ return _loadCurrentOrganization.apply(this, arguments);
577
+ }
578
+ return loadCurrentOrganization;
579
+ }()
580
+ }, {
581
+ key: "switchOrganization",
582
+ value: function () {
583
+ var _switchOrganization = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime().mark(function _callee16(orgId) {
584
+ return _regeneratorRuntime().wrap(function _callee16$(_context16) {
585
+ while (1) switch (_context16.prev = _context16.next) {
586
+ case 0:
587
+ return _context16.abrupt("return", this.api.switchOrganization(orgId));
588
+ case 1:
589
+ case "end":
590
+ return _context16.stop();
591
+ }
592
+ }, _callee16, this);
593
+ }));
594
+ function switchOrganization(_x10) {
521
595
  return _switchOrganization.apply(this, arguments);
522
596
  }
523
597
  return switchOrganization;
@@ -525,21 +599,21 @@ var Roboto = /*#__PURE__*/function () {
525
599
  }, {
526
600
  key: "selectCurrentOrganization",
527
601
  value: function () {
528
- var _selectCurrentOrganization = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime().mark(function _callee13(orgId) {
602
+ var _selectCurrentOrganization = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime().mark(function _callee17(orgId) {
529
603
  var role,
530
- _args13 = arguments;
531
- return _regeneratorRuntime().wrap(function _callee13$(_context13) {
532
- while (1) switch (_context13.prev = _context13.next) {
604
+ _args17 = arguments;
605
+ return _regeneratorRuntime().wrap(function _callee17$(_context17) {
606
+ while (1) switch (_context17.prev = _context17.next) {
533
607
  case 0:
534
- role = _args13.length > 1 && _args13[1] !== undefined ? _args13[1] : 'owner';
535
- return _context13.abrupt("return", this.api.selectCurrentOrganization(orgId, role));
608
+ role = _args17.length > 1 && _args17[1] !== undefined ? _args17[1] : 'owner';
609
+ return _context17.abrupt("return", this.api.selectCurrentOrganization(orgId, role));
536
610
  case 2:
537
611
  case "end":
538
- return _context13.stop();
612
+ return _context17.stop();
539
613
  }
540
- }, _callee13, this);
614
+ }, _callee17, this);
541
615
  }));
542
- function selectCurrentOrganization(_x7) {
616
+ function selectCurrentOrganization(_x11) {
543
617
  return _selectCurrentOrganization.apply(this, arguments);
544
618
  }
545
619
  return selectCurrentOrganization;
@@ -552,7 +626,7 @@ var Roboto = /*#__PURE__*/function () {
552
626
  }, {
553
627
  key: "currentOrganization",
554
628
  get: function get() {
555
- return this.api.currentOrganization;
629
+ return this.api.getCurrentOrganization();
556
630
  }
557
631
 
558
632
  //
@@ -561,19 +635,19 @@ var Roboto = /*#__PURE__*/function () {
561
635
  }, {
562
636
  key: "createFile",
563
637
  value: function () {
564
- var _createFile = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime().mark(function _callee14() {
638
+ var _createFile = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime().mark(function _callee18() {
565
639
  var data,
566
- _args14 = arguments;
567
- return _regeneratorRuntime().wrap(function _callee14$(_context14) {
568
- while (1) switch (_context14.prev = _context14.next) {
640
+ _args18 = arguments;
641
+ return _regeneratorRuntime().wrap(function _callee18$(_context18) {
642
+ while (1) switch (_context18.prev = _context18.next) {
569
643
  case 0:
570
- data = _args14.length > 0 && _args14[0] !== undefined ? _args14[0] : {};
571
- return _context14.abrupt("return", this.api.createFile(data));
644
+ data = _args18.length > 0 && _args18[0] !== undefined ? _args18[0] : {};
645
+ return _context18.abrupt("return", this.api.createFile(data));
572
646
  case 2:
573
647
  case "end":
574
- return _context14.stop();
648
+ return _context18.stop();
575
649
  }
576
- }, _callee14, this);
650
+ }, _callee18, this);
577
651
  }));
578
652
  function createFile() {
579
653
  return _createFile.apply(this, arguments);
@@ -583,18 +657,18 @@ var Roboto = /*#__PURE__*/function () {
583
657
  }, {
584
658
  key: "loadFile",
585
659
  value: function () {
586
- var _loadFile = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime().mark(function _callee15(id) {
587
- return _regeneratorRuntime().wrap(function _callee15$(_context15) {
588
- while (1) switch (_context15.prev = _context15.next) {
660
+ var _loadFile = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime().mark(function _callee19(id) {
661
+ return _regeneratorRuntime().wrap(function _callee19$(_context19) {
662
+ while (1) switch (_context19.prev = _context19.next) {
589
663
  case 0:
590
- return _context15.abrupt("return", this.api.loadFile(id));
664
+ return _context19.abrupt("return", this.api.loadFile(id));
591
665
  case 1:
592
666
  case "end":
593
- return _context15.stop();
667
+ return _context19.stop();
594
668
  }
595
- }, _callee15, this);
669
+ }, _callee19, this);
596
670
  }));
597
- function loadFile(_x8) {
671
+ function loadFile(_x12) {
598
672
  return _loadFile.apply(this, arguments);
599
673
  }
600
674
  return loadFile;
@@ -602,18 +676,18 @@ var Roboto = /*#__PURE__*/function () {
602
676
  }, {
603
677
  key: "loadFiles",
604
678
  value: function () {
605
- var _loadFiles = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime().mark(function _callee16(ids) {
606
- return _regeneratorRuntime().wrap(function _callee16$(_context16) {
607
- while (1) switch (_context16.prev = _context16.next) {
679
+ var _loadFiles = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime().mark(function _callee20(ids) {
680
+ return _regeneratorRuntime().wrap(function _callee20$(_context20) {
681
+ while (1) switch (_context20.prev = _context20.next) {
608
682
  case 0:
609
- return _context16.abrupt("return", this.api.loadFiles(ids));
683
+ return _context20.abrupt("return", this.api.loadFiles(ids));
610
684
  case 1:
611
685
  case "end":
612
- return _context16.stop();
686
+ return _context20.stop();
613
687
  }
614
- }, _callee16, this);
688
+ }, _callee20, this);
615
689
  }));
616
- function loadFiles(_x9) {
690
+ function loadFiles(_x13) {
617
691
  return _loadFiles.apply(this, arguments);
618
692
  }
619
693
  return loadFiles;
@@ -623,21 +697,21 @@ var Roboto = /*#__PURE__*/function () {
623
697
  }, {
624
698
  key: "create",
625
699
  value: function () {
626
- var _create = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime().mark(function _callee17(params) {
700
+ var _create = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime().mark(function _callee21(params) {
627
701
  var data,
628
- _args17 = arguments;
629
- return _regeneratorRuntime().wrap(function _callee17$(_context17) {
630
- while (1) switch (_context17.prev = _context17.next) {
702
+ _args21 = arguments;
703
+ return _regeneratorRuntime().wrap(function _callee21$(_context21) {
704
+ while (1) switch (_context21.prev = _context21.next) {
631
705
  case 0:
632
- data = _args17.length > 1 && _args17[1] !== undefined ? _args17[1] : {};
633
- return _context17.abrupt("return", this.api.create(params, data));
706
+ data = _args21.length > 1 && _args21[1] !== undefined ? _args21[1] : {};
707
+ return _context21.abrupt("return", this.api.create(params, data));
634
708
  case 2:
635
709
  case "end":
636
- return _context17.stop();
710
+ return _context21.stop();
637
711
  }
638
- }, _callee17, this);
712
+ }, _callee21, this);
639
713
  }));
640
- function create(_x10) {
714
+ function create(_x14) {
641
715
  return _create.apply(this, arguments);
642
716
  }
643
717
  return create;
@@ -645,18 +719,18 @@ var Roboto = /*#__PURE__*/function () {
645
719
  }, {
646
720
  key: "load",
647
721
  value: function () {
648
- var _load = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime().mark(function _callee18(type, ids, options) {
649
- return _regeneratorRuntime().wrap(function _callee18$(_context18) {
650
- while (1) switch (_context18.prev = _context18.next) {
722
+ var _load = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime().mark(function _callee22(type, ids, options) {
723
+ return _regeneratorRuntime().wrap(function _callee22$(_context22) {
724
+ while (1) switch (_context22.prev = _context22.next) {
651
725
  case 0:
652
- return _context18.abrupt("return", this.api.load(type, ids, options));
726
+ return _context22.abrupt("return", this.api.load(type, ids, options));
653
727
  case 1:
654
728
  case "end":
655
- return _context18.stop();
729
+ return _context22.stop();
656
730
  }
657
- }, _callee18, this);
731
+ }, _callee22, this);
658
732
  }));
659
- function load(_x11, _x12, _x13) {
733
+ function load(_x15, _x16, _x17) {
660
734
  return _load.apply(this, arguments);
661
735
  }
662
736
  return load;
@@ -664,18 +738,18 @@ var Roboto = /*#__PURE__*/function () {
664
738
  }, {
665
739
  key: "query",
666
740
  value: function () {
667
- var _query = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime().mark(function _callee19(type, params) {
668
- return _regeneratorRuntime().wrap(function _callee19$(_context19) {
669
- while (1) switch (_context19.prev = _context19.next) {
741
+ var _query = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime().mark(function _callee23(type, params) {
742
+ return _regeneratorRuntime().wrap(function _callee23$(_context23) {
743
+ while (1) switch (_context23.prev = _context23.next) {
670
744
  case 0:
671
- return _context19.abrupt("return", this.api.query(type, params));
745
+ return _context23.abrupt("return", this.api.query(type, params));
672
746
  case 1:
673
747
  case "end":
674
- return _context19.stop();
748
+ return _context23.stop();
675
749
  }
676
- }, _callee19, this);
750
+ }, _callee23, this);
677
751
  }));
678
- function query(_x14, _x15) {
752
+ function query(_x18, _x19) {
679
753
  return _query.apply(this, arguments);
680
754
  }
681
755
  return query;
@@ -697,18 +771,18 @@ var Roboto = /*#__PURE__*/function () {
697
771
  }, {
698
772
  key: "runTask",
699
773
  value: function () {
700
- var _runTask = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime().mark(function _callee20(params, callbacks) {
701
- return _regeneratorRuntime().wrap(function _callee20$(_context20) {
702
- while (1) switch (_context20.prev = _context20.next) {
774
+ var _runTask = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime().mark(function _callee24(params, callbacks) {
775
+ return _regeneratorRuntime().wrap(function _callee24$(_context24) {
776
+ while (1) switch (_context24.prev = _context24.next) {
703
777
  case 0:
704
- return _context20.abrupt("return", this.api.runTask(params, callbacks));
778
+ return _context24.abrupt("return", this.api.runTask(params, callbacks));
705
779
  case 1:
706
780
  case "end":
707
- return _context20.stop();
781
+ return _context24.stop();
708
782
  }
709
- }, _callee20, this);
783
+ }, _callee24, this);
710
784
  }));
711
- function runTask(_x16, _x17) {
785
+ function runTask(_x20, _x21) {
712
786
  return _runTask.apply(this, arguments);
713
787
  }
714
788
  return runTask;
@@ -716,18 +790,18 @@ var Roboto = /*#__PURE__*/function () {
716
790
  }, {
717
791
  key: "stopJob",
718
792
  value: function () {
719
- var _stopJob = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime().mark(function _callee21(params, callbacks) {
720
- return _regeneratorRuntime().wrap(function _callee21$(_context21) {
721
- while (1) switch (_context21.prev = _context21.next) {
793
+ var _stopJob = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime().mark(function _callee25(params, callbacks) {
794
+ return _regeneratorRuntime().wrap(function _callee25$(_context25) {
795
+ while (1) switch (_context25.prev = _context25.next) {
722
796
  case 0:
723
- return _context21.abrupt("return", this.api.stopJob(params, callbacks));
797
+ return _context25.abrupt("return", this.api.stopJob(params, callbacks));
724
798
  case 1:
725
799
  case "end":
726
- return _context21.stop();
800
+ return _context25.stop();
727
801
  }
728
- }, _callee21, this);
802
+ }, _callee25, this);
729
803
  }));
730
- function stopJob(_x18, _x19) {
804
+ function stopJob(_x22, _x23) {
731
805
  return _stopJob.apply(this, arguments);
732
806
  }
733
807
  return stopJob;
@@ -735,18 +809,18 @@ var Roboto = /*#__PURE__*/function () {
735
809
  }, {
736
810
  key: "pollTaskProgress",
737
811
  value: function () {
738
- var _pollTaskProgress = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime().mark(function _callee22(params) {
739
- return _regeneratorRuntime().wrap(function _callee22$(_context22) {
740
- while (1) switch (_context22.prev = _context22.next) {
812
+ var _pollTaskProgress = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime().mark(function _callee26(params) {
813
+ return _regeneratorRuntime().wrap(function _callee26$(_context26) {
814
+ while (1) switch (_context26.prev = _context26.next) {
741
815
  case 0:
742
- return _context22.abrupt("return", this.api.pollTaskProgress(params));
816
+ return _context26.abrupt("return", this.api.pollTaskProgress(params));
743
817
  case 1:
744
818
  case "end":
745
- return _context22.stop();
819
+ return _context26.stop();
746
820
  }
747
- }, _callee22, this);
821
+ }, _callee26, this);
748
822
  }));
749
- function pollTaskProgress(_x20) {
823
+ function pollTaskProgress(_x24) {
750
824
  return _pollTaskProgress.apply(this, arguments);
751
825
  }
752
826
  return pollTaskProgress;
@@ -811,23 +885,23 @@ var Roboto = /*#__PURE__*/function () {
811
885
  }, {
812
886
  key: "get",
813
887
  value: function () {
814
- var _get = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime().mark(function _callee23(endpoint, params) {
888
+ var _get = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime().mark(function _callee27(endpoint, params) {
815
889
  var result;
816
- return _regeneratorRuntime().wrap(function _callee23$(_context23) {
817
- while (1) switch (_context23.prev = _context23.next) {
890
+ return _regeneratorRuntime().wrap(function _callee27$(_context27) {
891
+ while (1) switch (_context27.prev = _context27.next) {
818
892
  case 0:
819
- _context23.next = 2;
893
+ _context27.next = 2;
820
894
  return this.api.get(endpoint, params);
821
895
  case 2:
822
- result = _context23.sent;
823
- return _context23.abrupt("return", this._autoWrapResponse(result));
896
+ result = _context27.sent;
897
+ return _context27.abrupt("return", this._autoWrapResponse(result));
824
898
  case 4:
825
899
  case "end":
826
- return _context23.stop();
900
+ return _context27.stop();
827
901
  }
828
- }, _callee23, this);
902
+ }, _callee27, this);
829
903
  }));
830
- function get(_x21, _x22) {
904
+ function get(_x25, _x26) {
831
905
  return _get.apply(this, arguments);
832
906
  }
833
907
  return get;
@@ -835,23 +909,23 @@ var Roboto = /*#__PURE__*/function () {
835
909
  }, {
836
910
  key: "post",
837
911
  value: function () {
838
- var _post = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime().mark(function _callee24(endpoint, data) {
912
+ var _post = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime().mark(function _callee28(endpoint, data) {
839
913
  var result;
840
- return _regeneratorRuntime().wrap(function _callee24$(_context24) {
841
- while (1) switch (_context24.prev = _context24.next) {
914
+ return _regeneratorRuntime().wrap(function _callee28$(_context28) {
915
+ while (1) switch (_context28.prev = _context28.next) {
842
916
  case 0:
843
- _context24.next = 2;
917
+ _context28.next = 2;
844
918
  return this.api.post(endpoint, data);
845
919
  case 2:
846
- result = _context24.sent;
847
- return _context24.abrupt("return", this._autoWrapResponse(result));
920
+ result = _context28.sent;
921
+ return _context28.abrupt("return", this._autoWrapResponse(result));
848
922
  case 4:
849
923
  case "end":
850
- return _context24.stop();
924
+ return _context28.stop();
851
925
  }
852
- }, _callee24, this);
926
+ }, _callee28, this);
853
927
  }));
854
- function post(_x23, _x24) {
928
+ function post(_x27, _x28) {
855
929
  return _post.apply(this, arguments);
856
930
  }
857
931
  return post;