merge: Bridged error message for when you try search for a post and it fails (!421)
View MR for information: https://activitypub.software/TransFem-org/Sharkey/-/merge_requests/421 Approved-by: dakkar <dakkar@thenautilus.net> Approved-by: Marie <marie@kaifa.ch>
This commit is contained in:
commit
764bbcf05b
@ -108,12 +108,19 @@ export function promiseDialog<T extends Promise<any>>(
|
||||
showing.value = false;
|
||||
if (onFailure) {
|
||||
onFailure(err);
|
||||
} else {
|
||||
if (err.message) {
|
||||
alert({
|
||||
type: 'error',
|
||||
text: err.message,
|
||||
});
|
||||
} else {
|
||||
alert({
|
||||
type: 'error',
|
||||
text: err,
|
||||
});
|
||||
}
|
||||
}
|
||||
});
|
||||
|
||||
// NOTE: dynamic importすると挙動がおかしくなる(showingの変更が伝播しない)
|
||||
|
Loading…
Reference in New Issue
Block a user