fixed missing lock in demo expire update
This commit is contained in:
@@ -128,7 +128,9 @@ func (p *DemoParser) parseWorker() {
|
||||
if err != nil {
|
||||
switch e := err.(type) {
|
||||
case DemoNotFoundError:
|
||||
p.lock.Lock()
|
||||
err := tMatch.Update().SetDemoExpired(true).Exec(context.Background())
|
||||
p.lock.Unlock()
|
||||
if err != nil {
|
||||
log.Errorf("[DP] Unable to set demo expire for match %d: %v", demo.MatchId, e)
|
||||
continue
|
||||
|
Reference in New Issue
Block a user