From 941be7d19abb590d931a7fecd13ae102bde04fcf Mon Sep 17 00:00:00 2001 From: chenlinghy Date: Mon, 8 Jun 2020 17:55:40 +0800 Subject: [PATCH] =?UTF-8?q?OCT=20REM:=201.=20=E4=BF=AE=E6=94=B9=E5=88=A0?= =?UTF-8?q?=E9=99=A4=E8=8A=82=E7=82=B9=E5=85=A5=E5=8F=82=E5=AD=97=E6=AE=B5?= =?UTF-8?q?=E7=9A=84=E5=88=A4=E6=96=AD?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../com/dispose/controller/DisposeNodeManagerController.java | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/src/main/java/com/dispose/controller/DisposeNodeManagerController.java b/src/main/java/com/dispose/controller/DisposeNodeManagerController.java index 5317223e..d6ef7831 100644 --- a/src/main/java/com/dispose/controller/DisposeNodeManagerController.java +++ b/src/main/java/com/dispose/controller/DisposeNodeManagerController.java @@ -144,13 +144,12 @@ public class DisposeNodeManagerController { IDArrayReq reqInfo = mr.getRequestObject(IDArrayReq.class); - if (reqInfo.getId() == null || Arrays.stream(reqInfo.getId()).anyMatch(Objects::isNull)) { + if (reqInfo.getId() == null) { log.error("Request params error, error:{}", mr.getMsgContent()); return ProtocolRespDTO.result(ErrorCode.ERR_PARAMS); } - if (reqInfo.getId().length > 1 - || Arrays.stream(reqInfo.getId()).anyMatch(v -> v.length() == 0)) { + if (reqInfo.getId()[0].length() == 0) { log.error("Prohibit deleting multiple devices at the same time"); return ProtocolRespDTO.result(ErrorCode.ERR_REMOVEMORE); }