aboutsummaryrefslogtreecommitdiff
path: root/packages/demobank-ui/src/pages/UpdateAccountPassword.tsx
diff options
context:
space:
mode:
authorSebastian <sebasjm@gmail.com>2023-10-23 15:49:13 -0300
committerSebastian <sebasjm@gmail.com>2023-10-23 15:49:35 -0300
commitc66f06eb73e53a8804b8c2b36ff45972836c633c (patch)
tree18461a0e29124326ccb70331971d5914f3ff56b3 /packages/demobank-ui/src/pages/UpdateAccountPassword.tsx
parent2512665e9462690162a5bae5fab3337217943269 (diff)
downloadwallet-core-c66f06eb73e53a8804b8c2b36ff45972836c633c.tar.xz
update conversion rate info, added test-bank-api in taler harness
Diffstat (limited to 'packages/demobank-ui/src/pages/UpdateAccountPassword.tsx')
-rw-r--r--packages/demobank-ui/src/pages/UpdateAccountPassword.tsx6
1 files changed, 4 insertions, 2 deletions
diff --git a/packages/demobank-ui/src/pages/UpdateAccountPassword.tsx b/packages/demobank-ui/src/pages/UpdateAccountPassword.tsx
index ef3737e81..f23285528 100644
--- a/packages/demobank-ui/src/pages/UpdateAccountPassword.tsx
+++ b/packages/demobank-ui/src/pages/UpdateAccountPassword.tsx
@@ -47,7 +47,7 @@ export function UpdateAccountPassword({
if (!!errors || !password || !token) return;
await withRuntimeErrorHandling(i18n, async () => {
const resp = await api.updatePassword({ username: accountName, token }, {
- // old_password: current,
+ old_password: current,
new_password: password,
});
if (resp.type === "ok") {
@@ -61,7 +61,9 @@ export function UpdateAccountPassword({
})
case "no-rights": return notify({
type: "error",
- title: i18n.str`This user have no right on to change the password.`
+ title: current ?
+ i18n.str`This user have no right on to change the password.` :
+ i18n.str`This user have no right on to change the password or the old password doesn't match.`
})
case "not-found": return notify({
type: "error",