修复时间戳校验失败的问题
This commit is contained in:
@@ -261,7 +261,7 @@ func (hs *HeartbeatService) handleHeartbeatWithStatus(deviceID string, tempStatu
|
||||
})
|
||||
|
||||
// 时间戳校验
|
||||
if response.Timestamp != heartbeatData["timestamp"] {
|
||||
if response.Timestamp.Unix() != heartbeatData["timestamp"] {
|
||||
hs.logger.Error(fmt.Sprintf("心跳响应时间戳校验失败: %v , 响应时间戳应当与发送的时间戳一致", response))
|
||||
return errors.New("心跳响应时间戳校验失败")
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user