diff --git a/ruoyi-flyingbook/src/main/java/com/ruoyi/flyingbook/controller/EdiController.java b/ruoyi-flyingbook/src/main/java/com/ruoyi/flyingbook/controller/EdiController.java index 9e61d4d..671a073 100644 --- a/ruoyi-flyingbook/src/main/java/com/ruoyi/flyingbook/controller/EdiController.java +++ b/ruoyi-flyingbook/src/main/java/com/ruoyi/flyingbook/controller/EdiController.java @@ -14,6 +14,7 @@ import com.ruoyi.flyingbook.edi.EdiOperateService; import com.ruoyi.flyingbook.service.IEventLogService; import lombok.extern.slf4j.Slf4j; import org.apache.commons.codec.binary.Base64; +import org.apache.commons.lang3.StringUtils; import org.springframework.beans.factory.annotation.Autowired; import org.springframework.core.io.ResourceLoader; import org.springframework.web.bind.annotation.*; @@ -73,7 +74,9 @@ public class EdiController extends BaseController { JSONObject jsonObject = JSONObject.parseObject(encryptMsg); JSONObject bizContent = jsonObject.getJSONObject("bizContent"); String appTicket = bizContent.getString("appTicket"); - redisCache.setCacheObject(RedisConstants.CJT_TICKET_CACHE_KEY,appTicket,10, TimeUnit.MINUTES); + if (StringUtils.isNotBlank(appTicket)) { + redisCache.setCacheObject(RedisConstants.CJT_TICKET_CACHE_KEY,appTicket,10, TimeUnit.MINUTES); + } }catch (Exception e){ log.error("receiveWscTicket error request:{}",JSONObject.toJSONString(request),e); }