From d7a1fc6d449117d0f2901cb10d98c3eb00d92fc3 Mon Sep 17 00:00:00 2001 From: Ryan G <78384369+SpongeManiac@users.noreply.github.com> Date: Tue, 13 Jun 2023 00:02:50 -0700 Subject: [PATCH] Update authentication.cr --- src/invidious/routes/api/v1/authentication.cr | 6 +----- 1 file changed, 1 insertion(+), 5 deletions(-) diff --git a/src/invidious/routes/api/v1/authentication.cr b/src/invidious/routes/api/v1/authentication.cr index 326c42cc..5ea6e99c 100644 --- a/src/invidious/routes/api/v1/authentication.cr +++ b/src/invidious/routes/api/v1/authentication.cr @@ -36,11 +36,7 @@ module Invidious::Routes::API::V1::Authentication password = password.byte_slice(0, 55) # send captcha if enabled if CONFIG.captcha_enabled - captcha_response = nil - begin - captcha_response = CaptchaResponse.from_json(env.request.body || "{}") - rescue - end + captcha_response = CaptchaResponse.from_json(env.request.body || "{}") if captcha_response answer = captcha_response.answer tokens = captcha_response.tokens