删除 冗余代码

This commit is contained in:
dengsgo 2018-12-30 15:16:47 +08:00
parent afcceb7753
commit 7604ec07f7

View File

@ -33,8 +33,7 @@ func (t *TaskMan) Put(cf *changeFile) {
defer t.putLock.Unlock() defer t.putLock.Unlock()
t.lastTaskId = cf.Changed t.lastTaskId = cf.Changed
go func() { go func() {
tc := time.Tick(time.Millisecond * time.Duration(t.delay)) <- time.Tick(time.Millisecond * time.Duration(t.delay))
<-tc
if t.lastTaskId > cf.Changed { if t.lastTaskId > cf.Changed {
return return
} }