From 4ce85fdb19f313e07197b2f054d0ac78e9265b8b Mon Sep 17 00:00:00 2001 From: Jon Chambers Date: Wed, 25 Jan 2023 14:34:38 -0500 Subject: [PATCH] Treat "check code" exceptions as `false` for legacy API compatibility --- .../textsecuregcm/controllers/AccountController.java | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/service/src/main/java/org/whispersystems/textsecuregcm/controllers/AccountController.java b/service/src/main/java/org/whispersystems/textsecuregcm/controllers/AccountController.java index 0f54d2a80..9092ece0d 100644 --- a/service/src/main/java/org/whispersystems/textsecuregcm/controllers/AccountController.java +++ b/service/src/main/java/org/whispersystems/textsecuregcm/controllers/AccountController.java @@ -997,7 +997,9 @@ public class AccountController { return registrationServiceClient.checkVerificationCode(sessionId, verificationCode, REGISTRATION_RPC_TIMEOUT).join(); } catch (final CompletionException e) { rethrowRateLimitException(e); - throw e; + + // For legacy API compatibility, funnel all errors into the same return value + return false; } }