ywana-core8 0.1.33 → 0.1.34

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/dist/index.umd.js CHANGED
@@ -2570,8 +2570,10 @@
2570
2570
  var ForgetUserPasswordAction = function ForgetUserPasswordAction(props) {
2571
2571
  var execute = function execute() {
2572
2572
  try {
2573
- var _temp = _catch$7(function () {
2574
- return Promise.resolve(onOK(user.email)).then(function () {
2573
+ return Promise.resolve(_catch$7(function () {
2574
+ var email = user.email;
2575
+ if (!email) throw new Error("Email not found");
2576
+ return Promise.resolve(onOK(email)).then(function () {
2575
2577
  if (onSuccess) onSuccess();
2576
2578
  site.notify({
2577
2579
  title: /*#__PURE__*/React__default["default"].createElement(Text$1, null, "Forgot Password"),
@@ -2586,8 +2588,7 @@
2586
2588
  type: "danger",
2587
2589
  icon: "error"
2588
2590
  });
2589
- });
2590
- return Promise.resolve(_temp && _temp.then ? _temp.then(function () {}) : void 0);
2591
+ }));
2591
2592
  } catch (e) {
2592
2593
  return Promise.reject(e);
2593
2594
  }
@@ -2619,7 +2620,7 @@
2619
2620
  var UnlockUserAction = function UnlockUserAction(props) {
2620
2621
  var execute = function execute() {
2621
2622
  try {
2622
- var _temp2 = _catch$7(function () {
2623
+ var _temp = _catch$7(function () {
2623
2624
  return Promise.resolve(onOK(user)).then(function () {
2624
2625
  if (onSuccess) onSuccess();
2625
2626
  site.notify({
@@ -2636,7 +2637,7 @@
2636
2637
  icon: "error"
2637
2638
  });
2638
2639
  });
2639
- return Promise.resolve(_temp2 && _temp2.then ? _temp2.then(function () {}) : void 0);
2640
+ return Promise.resolve(_temp && _temp.then ? _temp.then(function () {}) : void 0);
2640
2641
  } catch (e) {
2641
2642
  return Promise.reject(e);
2642
2643
  }
@@ -2686,7 +2687,7 @@
2686
2687
  function execute() {
2687
2688
  var onOK = function onOK(form) {
2688
2689
  try {
2689
- var _temp3 = _catch$7(function () {
2690
+ var _temp2 = _catch$7(function () {
2690
2691
  return Promise.resolve(props.onOK(user, form.oldPassword, form.password1)).then(function () {
2691
2692
  site.notify({
2692
2693
  title: /*#__PURE__*/React__default["default"].createElement(Text$1, null, "Change Password"),
@@ -2711,7 +2712,7 @@
2711
2712
  error: message
2712
2713
  }));
2713
2714
  });
2714
- return Promise.resolve(_temp3 && _temp3.then ? _temp3.then(function () {}) : void 0);
2715
+ return Promise.resolve(_temp2 && _temp2.then ? _temp2.then(function () {}) : void 0);
2715
2716
  } catch (e) {
2716
2717
  return Promise.reject(e);
2717
2718
  }