From 3e352b338c0302bec20f6046984795d4913ddb94 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E4=BD=95=E5=BB=BA?= <2265009218@qq.com> Date: Wed, 11 Dec 2024 16:37:59 +0800 Subject: [PATCH] =?UTF-8?q?=E9=AA=8C=E8=AF=81=E7=A0=81=E7=94=9F=E6=88=90?= =?UTF-8?q?=E4=BC=98=E5=8C=96=EF=BC=8C=E5=88=A0=E9=99=A4=E4=B8=8D=E4=BC=9A?= =?UTF-8?q?=E5=88=B0=E8=BE=BE=E7=9A=84else=E5=88=A4=E6=96=AD?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../com/ruoyi/gateway/config/KaptchaTextCreator.java | 9 +-------- 1 file changed, 1 insertion(+), 8 deletions(-) diff --git a/ruoyi-gateway/src/main/java/com/ruoyi/gateway/config/KaptchaTextCreator.java b/ruoyi-gateway/src/main/java/com/ruoyi/gateway/config/KaptchaTextCreator.java index ea65aef7..179c2c86 100644 --- a/ruoyi-gateway/src/main/java/com/ruoyi/gateway/config/KaptchaTextCreator.java +++ b/ruoyi-gateway/src/main/java/com/ruoyi/gateway/config/KaptchaTextCreator.java @@ -45,7 +45,7 @@ public class KaptchaTextCreator extends DefaultTextCreator suChinese.append(CNUMBERS[y]); } } - else if (randomoperands == 2) + else { if (x >= y) { @@ -62,13 +62,6 @@ public class KaptchaTextCreator extends DefaultTextCreator suChinese.append(CNUMBERS[x]); } } - else - { - result = x + y; - suChinese.append(CNUMBERS[x]); - suChinese.append("+"); - suChinese.append(CNUMBERS[y]); - } suChinese.append("=?@" + result); return suChinese.toString(); }