react-redux-django-auth 1.3.5 → 1.3.7
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.js +2 -8
- package/dist/index.mjs +4 -6
- package/package.json +1 -1
package/dist/index.js
CHANGED
|
@@ -1576,13 +1576,6 @@ var useChangeAuthenticatedUserPassword = function(initialFields, apiUrl) {
|
|
|
1576
1576
|
case 0:
|
|
1577
1577
|
e.preventDefault();
|
|
1578
1578
|
current_password = formData.current_password, new_password = formData.new_password, re_new_password = formData.re_new_password;
|
|
1579
|
-
if (new_password !== re_new_password) {
|
|
1580
|
-
setError("New passwords do not match.");
|
|
1581
|
-
return [
|
|
1582
|
-
2
|
|
1583
|
-
];
|
|
1584
|
-
}
|
|
1585
|
-
setError(null);
|
|
1586
1579
|
setLoading(true);
|
|
1587
1580
|
_state.label = 1;
|
|
1588
1581
|
case 1:
|
|
@@ -1596,7 +1589,8 @@ var useChangeAuthenticatedUserPassword = function(initialFields, apiUrl) {
|
|
|
1596
1589
|
4,
|
|
1597
1590
|
dispatch(changeLoggedInUserPassword({
|
|
1598
1591
|
current_password: current_password,
|
|
1599
|
-
new_password: new_password
|
|
1592
|
+
new_password: new_password,
|
|
1593
|
+
re_new_password: re_new_password
|
|
1600
1594
|
}, apiUrl))
|
|
1601
1595
|
];
|
|
1602
1596
|
case 2:
|
package/dist/index.mjs
CHANGED
|
@@ -608,15 +608,13 @@ var useChangeAuthenticatedUserPassword = (initialFields, apiUrl) => {
|
|
|
608
608
|
async (e) => {
|
|
609
609
|
e.preventDefault();
|
|
610
610
|
const { current_password, new_password, re_new_password } = formData;
|
|
611
|
-
if (new_password !== re_new_password) {
|
|
612
|
-
setError("New passwords do not match.");
|
|
613
|
-
return;
|
|
614
|
-
}
|
|
615
|
-
setError(null);
|
|
616
611
|
setLoading(true);
|
|
617
612
|
try {
|
|
618
613
|
await dispatch(
|
|
619
|
-
changeLoggedInUserPassword(
|
|
614
|
+
changeLoggedInUserPassword(
|
|
615
|
+
{ current_password, new_password, re_new_password },
|
|
616
|
+
apiUrl
|
|
617
|
+
)
|
|
620
618
|
);
|
|
621
619
|
} catch (err) {
|
|
622
620
|
console.error("Error submitting form", err);
|