From 97f61d05d0591052352228f372c94827155180df Mon Sep 17 00:00:00 2001 From: jay <75509151@qq.com> Date: Wed, 12 Jun 2024 21:00:16 +0800 Subject: [PATCH] =?UTF-8?q?fix=20=E6=9C=AA=E6=B3=A8=E5=86=8C=E8=AE=BE?= =?UTF-8?q?=E5=A4=87=E6=9B=B4=E6=96=B0=E6=9C=80=E6=96=B0=E9=80=9A=E8=AE=AF?= =?UTF-8?q?=E6=97=B6=E9=97=B4=E5=AF=BC=E8=87=B4=E6=B3=A8=E5=86=8C=E5=A4=B1?= =?UTF-8?q?=E8=B4=A5?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../main/java/cc/iotkit/plugin/main/ThingServiceImpl.java | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/iot-module/iot-plugin/iot-plugin-main/src/main/java/cc/iotkit/plugin/main/ThingServiceImpl.java b/iot-module/iot-plugin/iot-plugin-main/src/main/java/cc/iotkit/plugin/main/ThingServiceImpl.java index 3482b45e..303dc6d7 100644 --- a/iot-module/iot-plugin/iot-plugin-main/src/main/java/cc/iotkit/plugin/main/ThingServiceImpl.java +++ b/iot-module/iot-plugin/iot-plugin-main/src/main/java/cc/iotkit/plugin/main/ThingServiceImpl.java @@ -84,9 +84,11 @@ public class ThingServiceImpl implements IThingService { DeviceInfo device = getDeviceInfo(deviceName); if (device == null) { log.warn("device:{} is not found.", deviceName); + }else { + long lastTime = System.currentTimeMillis(); + deviceUpdateLastTime(device, lastTime); } - long lastTime = System.currentTimeMillis(); - deviceUpdateLastTime(device, lastTime); + ActionType type = action.getType(); switch (type) {