hashing password
This commit is contained in:
1 parent
5432e18a77
commit
c26cb038f7
6 files changed
+17
-12
No files matched your search
@@ -38,7 +38,10 @@ changeuserformbody.addEventListener('submit', async (e) => {
|
||||
is_superuser: changeuserformissuperuser.checked ? "1" : "0",
|
||||
group: changeuserformgroup.value
|
||||
};
|
||||
if (changeuserformpassword.value !== "") {request = {...request, "password": changeuserformpassword.value}}
|
||||
if (changeuserformpassword.value !== "") {
|
||||
const hashedpassword = await hashPassword(changeuserformpassword.value)
|
||||
request = {...request, "password": hashedpassword}
|
||||
}
|
||||
const status = await fetch(routes.change_user(), {
|
||||
method: 'POST',
|
||||
body: JSON.stringify(request)
|
||||
|
||||
Reference in new issue
Block a user