Skip to content
This repository has been archived by the owner on Jul 12, 2023. It is now read-only.

Return 400 on Twilio errors #1313

Merged
merged 1 commit into from
Dec 10, 2020
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions pkg/controller/issueapi/logic.go
Original file line number Diff line number Diff line change
Expand Up @@ -265,13 +265,13 @@ func (c *Controller) issue(ctx context.Context, request *api.IssueCodeRequest) (
}

logger.Errorw("failed to send sms", "error", err)
result.obsBlame = observability.BlameServer
result.obsBlame = observability.BlameClient
result.obsResult = observability.ResultError("FAILED_TO_SEND_SMS")
return err
}
return nil
}(); err != nil {
result.httpCode = http.StatusInternalServerError
result.httpCode = http.StatusBadRequest
result.errorReturn = api.Errorf("failed to send sms: %s", err)
return result, nil
}
Expand Down