From 28d5cd18748d1e4831fe0af5994ca9c139b5d35a Mon Sep 17 00:00:00 2001 From: Kang Ming Date: Fri, 10 Jan 2025 11:21:37 -0800 Subject: [PATCH 1/2] fix: improve invalid channel error message returned --- internal/api/errors.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/internal/api/errors.go b/internal/api/errors.go index 17c1474284..519f81d4e1 100644 --- a/internal/api/errors.go +++ b/internal/api/errors.go @@ -20,7 +20,7 @@ var ( UserExistsError error = errors.New("user already exists") ) -const InvalidChannelError = "Invalid channel, supported values are 'sms' or 'whatsapp'" +const InvalidChannelError = "Invalid channel, supported values are 'sms' or 'whatsapp'. 'whatsapp' is only supported if twilio or twilio verify is used as the provider." var oauthErrorMap = map[int]string{ http.StatusBadRequest: "invalid_request", From d9a27c9898384d5959be7f687b9969321f6eb8ce Mon Sep 17 00:00:00 2001 From: Kang Ming Date: Mon, 13 Jan 2025 12:10:24 -0800 Subject: [PATCH 2/2] chore: uppercase key terms Co-authored-by: Stojan Dimitrovski --- internal/api/errors.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/internal/api/errors.go b/internal/api/errors.go index 519f81d4e1..0ce9512e3d 100644 --- a/internal/api/errors.go +++ b/internal/api/errors.go @@ -20,7 +20,7 @@ var ( UserExistsError error = errors.New("user already exists") ) -const InvalidChannelError = "Invalid channel, supported values are 'sms' or 'whatsapp'. 'whatsapp' is only supported if twilio or twilio verify is used as the provider." +const InvalidChannelError = "Invalid channel, supported values are 'sms' or 'whatsapp'. 'whatsapp' is only supported if Twilio or Twilio Verify is used as the provider." var oauthErrorMap = map[int]string{ http.StatusBadRequest: "invalid_request",