Skip to content

Commit

Permalink
Merge pull request #671 from twin-te/fix/error-message
Browse files Browse the repository at this point in the history
Use original response error message
  • Loading branch information
HosokawaR authored Apr 6, 2023
2 parents 9b674df + 820b684 commit 391f56a
Showing 1 changed file with 1 addition and 6 deletions.
7 changes: 1 addition & 6 deletions src/infrastructure/api/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -58,12 +58,7 @@ export class Api {
status: FS,
originalResponse: { data: { message: string } }
): ApiFailedStatueToError[FS] {
const message =
status === 400
? "Bad Request"
: status === 500
? originalResponse.data.message
: undefined;
const message = originalResponse.data.message;
return apiFailedStatusToError[status](message);
}

Expand Down

1 comment on commit 391f56a

@vercel
Copy link

@vercel vercel bot commented on 391f56a Apr 6, 2023

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Successfully deployed to the following URLs:

twinte-front-staging – ./

app.dev.twinte.net
twinte-front-staging-twin-te.vercel.app
twinte-front-staging-git-main-twin-te.vercel.app

Please sign in to comment.