password change UI (#543)

This commit is contained in:
Christoph
2025-10-13 18:27:30 +02:00
parent 139fb17f98
commit b779f935e6
9 changed files with 459 additions and 178 deletions

View File

@@ -151,6 +151,17 @@ export const profileStore = defineStore('profile', {
})
})
},
async changePassword(formData) {
this.fetching = true
let currentUser = authStore().user.Identifier
return apiWrapper.post(`${baseUrl}/${base64_url_encode(currentUser)}/change-password`, formData)
.then(this.fetching = false)
.catch(error => {
this.fetching = false;
console.log("Failed to change password for ", currentUser, ": ", error);
throw new Error(error);
});
},
async LoadPeers() {
this.fetching = true
let currentUser = authStore().user.Identifier