fix admin password reset: send new_password (was password)
The reset endpoint's schema expects new_password; the client sent password, causing "body.new_password: Field required". Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
This commit is contained in:
@@ -38,7 +38,7 @@ export function updateAccess(userId: number, hasAccess: boolean) {
|
||||
|
||||
export function resetPassword(userId: number, password: string) {
|
||||
return apiClient
|
||||
.put<{ message: string }>(`admin/users/${userId}/password`, { password })
|
||||
.put<{ message: string }>(`admin/users/${userId}/password`, { new_password: password })
|
||||
.then((r) => r.data);
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user