react-email-widget
Advanced tools
Comparing version 1.0.1 to 1.0.2
@@ -71,2 +71,3 @@ "use strict"; | ||
var _ref = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime().mark(function _callee() { | ||
var response, jsonResponse; | ||
return _regeneratorRuntime().wrap(function _callee$(_context) { | ||
@@ -113,16 +114,25 @@ while (1) switch (_context.prev = _context.next) { | ||
case 18: | ||
setEmail(""); | ||
setMessage(""); | ||
setSuccess(true); | ||
_context.next = 26; | ||
response = _context.sent; | ||
_context.next = 21; | ||
return response.json(); | ||
case 21: | ||
jsonResponse = _context.sent; | ||
if (jsonResponse.error) { | ||
setError(jsonResponse.error); | ||
} else if (jsonResponse.status === "SUCCESS") { | ||
setEmail(""); | ||
setMessage(""); | ||
setSuccess(true); | ||
} | ||
_context.next = 28; | ||
break; | ||
case 23: | ||
_context.prev = 23; | ||
case 25: | ||
_context.prev = 25; | ||
_context.t0 = _context["catch"](15); | ||
setError(generalErrorText); | ||
case 26: | ||
case 28: | ||
case "end": | ||
return _context.stop(); | ||
} | ||
}, _callee, null, [[15, 23]]); | ||
}, _callee, null, [[15, 25]]); | ||
})); | ||
@@ -129,0 +139,0 @@ return function sendMail() { |
{ | ||
"name": "react-email-widget", | ||
"version": "1.0.1", | ||
"version": "1.0.2", | ||
"description": "A react widget with integrated email functionality towards algoook.info free email API", | ||
@@ -5,0 +5,0 @@ "main": "./dist/index.js", |
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
Major refactor
Supply chain riskPackage has recently undergone a major refactor. It may be unstable or indicate significant internal changes. Use caution when updating to versions that include significant changes.
Found 1 instance in 1 package
26958
333
1