mirror of
https://github.com/hexastack/hexabot
synced 2025-06-26 18:27:28 +00:00
fix: error message
This commit is contained in:
parent
c9e846e834
commit
1b455c9e05
@ -58,7 +58,7 @@ export const ContentTypeDialog: FC<ContentTypeDialogProps> = ({
|
||||
};
|
||||
const { mutate: createContentType } = useCreate(EntityType.CONTENT_TYPE, {
|
||||
onError: (error) => {
|
||||
toast.error(error);
|
||||
toast.error(error.message || t("message.internal_server_error"));
|
||||
},
|
||||
onSuccess: () => {
|
||||
closeDialog();
|
||||
@ -66,8 +66,8 @@ export const ContentTypeDialog: FC<ContentTypeDialogProps> = ({
|
||||
},
|
||||
});
|
||||
const { mutate: updateContentType } = useUpdate(EntityType.CONTENT_TYPE, {
|
||||
onError: () => {
|
||||
toast.error(t("message.internal_server_error"));
|
||||
onError: (error) => {
|
||||
toast.error(error.message || t("message.internal_server_error"));
|
||||
},
|
||||
onSuccess: () => {
|
||||
closeDialog();
|
||||
|
Loading…
Reference in New Issue
Block a user