Skip to content

armgit / umami

Public Imported from GitHub
0

Umami is a privacy-first web and product analytics platform. Traffic, campaigns, behavior, conversions, and revenue in one place. No cookies, no surveillance, self-hosted or in the cloud.

Fix user save bug with password field not clearing

Francis Caof9f9125532a8
diff --git a/src/app/(main)/admin/users/[userId]/UserEditForm.tsx b/src/app/(main)/admin/users/[userId]/UserEditForm.tsx
index 28bf030f5..68aa7f6e1 100644
--- a/src/app/(main)/admin/users/[userId]/UserEditForm.tsx
+++ b/src/app/(main)/admin/users/[userId]/UserEditForm.tsx
@@ -30,7 +30,11 @@ export function UserEditForm({ userId, onSave }: { userId: string; onSave?: () =
};
return (
- <Form onSubmit={handleSubmit} error={getMessage(error?.code)} values={user}>
+ <Form
+ onSubmit={handleSubmit}
+ error={getMessage(error?.code)}
+ values={{ ...user, password: '' }}
+ >
<FormField name="username" label={formatMessage(labels.username)}>
<TextField data-test="input-username" />
</FormField>