Improve type safety

This commit is contained in:
2023-04-22 09:28:42 +02:00
parent b62936ed54
commit 1cd9d83910
6 changed files with 37 additions and 13 deletions

View File

@ -10,8 +10,7 @@ export const handleError = (({ error }) => {
}
return {
message: 'Whoops!',
code: (error as any)?.code ?? 'UNKNOWN'
message: `Something went wrong! ${error}`
};
}) satisfies HandleServerError;