Compare commits
2 Commits
fa554de402
...
9f21e7c1d5
| Author | SHA1 | Date |
|---|---|---|
|
|
9f21e7c1d5 | |
|
|
e651a844f5 |
|
|
@ -274,7 +274,7 @@ func subscribeAndHandleMessages(ws *websocket.Conn, device_id int) {
|
|||
}
|
||||
}
|
||||
//查看是否还有其他连接,没有则设置is_play为0
|
||||
if worker.GetRedisSetMembers(online_conn_key) == nil {
|
||||
if worker.IsContainKey(online_conn_key) == false {
|
||||
worker.SetRedisWithExpire(strconv.Itoa(device_id)+"_is_play", "0", time.Minute*5)
|
||||
fmt.Println("device_id:", device_id, " has set is_play to 0")
|
||||
}
|
||||
|
|
|
|||
Loading…
Reference in New Issue