Skip to content

Commit

Permalink
Remove unneeded condition
Browse files Browse the repository at this point in the history
  • Loading branch information
clavin committed Jul 23, 2019
1 parent f73fa10 commit a6b22bc
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions packages/events-api/src/http-handler.ts
Original file line number Diff line number Diff line change
Expand Up @@ -63,10 +63,10 @@ export function createHTTPHandler(adapter: SlackEventAdapter): HTTPHandler {
if (!isFalsy(err)) {
if ('status' in err && typeof err.status === 'number') {
res.statusCode = err.status;
} else if ('code' in err && (
} else if (
(err as CodedError).code === ErrorCode.SignatureVerificationFailure ||
(err as CodedError).code === ErrorCode.RequestTimeFailure
)) {
) {
res.statusCode = ResponseStatus.NotFound;
} else {
res.statusCode = ResponseStatus.Failure;
Expand Down

0 comments on commit a6b22bc

Please sign in to comment.