去掉select 语句的break关键字

This commit is contained in:
陈景阳
2019-12-17 10:07:38 +08:00
parent c64ea5c250
commit 232c299949

View File

@@ -49,10 +49,8 @@ func GetRemoteLog(task model.Task) (logStr string, err error) {
select {
case logStr = <-ch:
log.Infof("get remote log")
break
case <-time.After(30 * time.Second):
logStr = "get remote log timeout"
break
}
return logStr, nil