mirror of
https://github.com/pixelfed/pixelfed.git
synced 2024-11-10 00:34:50 +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();
|
this.$refs.visitorContextMenu.hide();
|
||||||
swal('Success', 'You have successfully muted ' + this.profile.acct, 'success');
|
swal('Success', 'You have successfully muted ' + this.profile.acct, 'success');
|
||||||
}).catch(err => {
|
}).catch(err => {
|
||||||
|
if(err.response.status == 422) {
|
||||||
|
swal('Error', err.response.data.error, 'error');
|
||||||
|
} else {
|
||||||
swal('Error', 'Something went wrong. Please try again later.', 'error');
|
swal('Error', 'Something went wrong. Please try again later.', 'error');
|
||||||
|
}
|
||||||
});
|
});
|
||||||
},
|
},
|
||||||
|
|
||||||
|
@ -1113,7 +1117,11 @@
|
||||||
this.$refs.visitorContextMenu.hide();
|
this.$refs.visitorContextMenu.hide();
|
||||||
swal('Success', 'You have successfully blocked ' + this.profile.acct, 'success');
|
swal('Success', 'You have successfully blocked ' + this.profile.acct, 'success');
|
||||||
}).catch(err => {
|
}).catch(err => {
|
||||||
|
if(err.response.status == 422) {
|
||||||
|
swal('Error', err.response.data.error, 'error');
|
||||||
|
} else {
|
||||||
swal('Error', 'Something went wrong. Please try again later.', 'error');
|
swal('Error', 'Something went wrong. Please try again later.', 'error');
|
||||||
|
}
|
||||||
});
|
});
|
||||||
},
|
},
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue