mirror of
https://github.com/fosrl/pangolin.git
synced 2026-08-06 12:41:25 +02:00
refactor and reorganize
This commit is contained in:
@@ -0,0 +1,8 @@
|
||||
export function formatAxiosError(error: any, defaultMessage?: string): string {
|
||||
return (
|
||||
error.response?.data?.message ||
|
||||
error?.message ||
|
||||
defaultMessage ||
|
||||
"An error occurred"
|
||||
);
|
||||
}
|
||||
Reference in New Issue
Block a user