mirror of
https://github.com/pixelfed/pixelfed.git
synced 2024-11-25 15:55:22 +00:00
Update Profile component, improve error messages when block/mute limit reached
This commit is contained in:
parent
bc16b936d6
commit
02237845b5
1 changed files with 10 additions and 2 deletions
|
@ -1078,7 +1078,11 @@
|
|||
this.$refs.visitorContextMenu.hide();
|
||||
swal('Success', 'You have successfully muted ' + this.profile.acct, 'success');
|
||||
}).catch(err => {
|
||||
swal('Error', 'Something went wrong. Please try again later.', 'error');
|
||||
if(err.response.status == 422) {
|
||||
swal('Error', err.response.data.error, 'error');
|
||||
} else {
|
||||
swal('Error', 'Something went wrong. Please try again later.', 'error');
|
||||
}
|
||||
});
|
||||
},
|
||||
|
||||
|
@ -1113,7 +1117,11 @@
|
|||
this.$refs.visitorContextMenu.hide();
|
||||
swal('Success', 'You have successfully blocked ' + this.profile.acct, 'success');
|
||||
}).catch(err => {
|
||||
swal('Error', 'Something went wrong. Please try again later.', 'error');
|
||||
if(err.response.status == 422) {
|
||||
swal('Error', err.response.data.error, 'error');
|
||||
} else {
|
||||
swal('Error', 'Something went wrong. Please try again later.', 'error');
|
||||
}
|
||||
});
|
||||
},
|
||||
|
||||
|
|
Loading…
Reference in a new issue