From aad58640dcaab7bed4f9720b57bb7f0cc2c4e343 Mon Sep 17 00:00:00 2001
From: Sxile <3440626@qq.com>
Date: 星期五, 17 七月 2020 11:10:14 +0800
Subject: [PATCH] 翻转""为equals调用方,防止空指针异常

---
 ruoyi/src/main/java/com/ruoyi/common/utils/VerifyCodeUtils.java |    6 ++++--
 1 files changed, 4 insertions(+), 2 deletions(-)

diff --git a/ruoyi/src/main/java/com/ruoyi/common/utils/VerifyCodeUtils.java b/ruoyi/src/main/java/com/ruoyi/common/utils/VerifyCodeUtils.java
index 80b8c84..0417181 100644
--- a/ruoyi/src/main/java/com/ruoyi/common/utils/VerifyCodeUtils.java
+++ b/ruoyi/src/main/java/com/ruoyi/common/utils/VerifyCodeUtils.java
@@ -139,10 +139,12 @@
 
     private static Color getRandColor(int fc, int bc)
     {
-        if (fc > 255)
+        if (fc > 255) {
             fc = 255;
-        if (bc > 255)
+        }
+        if (bc > 255) {
             bc = 255;
+        }
         int r = fc + random.nextInt(bc - fc);
         int g = fc + random.nextInt(bc - fc);
         int b = fc + random.nextInt(bc - fc);

--
Gitblit v1.9.2