summaryrefslogtreecommitdiff
path: root/pages
diff options
context:
space:
mode:
authorSanto Cariotti <santo@dcariotti.me>2022-10-17 08:25:33 +0200
committerSanto Cariotti <santo@dcariotti.me>2022-10-17 08:25:33 +0200
commit16357c0e48bf1006d1fd81f944aa0ac5ddd1e70d (patch)
tree7a978c0f58153646c86b455d4773ca640f16ef51 /pages
parenta1b648b2bb9960d5697f8fee8a6ce7f42f896744 (diff)
admin: Delete an user avatar
Diffstat (limited to 'pages')
-rw-r--r--pages/settings.vue18
1 files changed, 8 insertions, 10 deletions
diff --git a/pages/settings.vue b/pages/settings.vue
index 5a74ced..8b8bad7 100644
--- a/pages/settings.vue
+++ b/pages/settings.vue
@@ -124,16 +124,14 @@ export default {
});
},
deleteAvatar() {
- this.$store
- .dispatch("users/deleteAvatar", this.me.id)
- .then((response) => {
- if (response.status == 200) {
- this.$toast.success("Avatar has been removed");
- this.avatarChanged = true;
- } else {
- this.$toast.error("Error removing");
- }
- });
+ this.$store.dispatch("users/deleteAvatar").then((response) => {
+ if (response.status == 200) {
+ this.$toast.success("Avatar has been removed");
+ this.avatarChanged = true;
+ } else {
+ this.$toast.error("Error removing");
+ }
+ });
},
save(event) {
const f = this.form;