mirror of
https://github.com/containous/traefik.git
synced 2025-10-16 23:33:20 +03:00
refactor: add Safe everywhere is needing.
This commit is contained in:
committed by
Ludovic Fernandez
parent
3174fb8861
commit
c36e0b3b06
@@ -80,7 +80,7 @@ func (d *Datastore) watchChanges() error {
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
go func() {
|
||||
safe.Go(func() {
|
||||
ctx, cancel := context.WithCancel(d.ctx)
|
||||
operation := func() error {
|
||||
for {
|
||||
@@ -113,7 +113,7 @@ func (d *Datastore) watchChanges() error {
|
||||
if err != nil {
|
||||
log.Errorf("Error in watch datastore: %v", err)
|
||||
}
|
||||
}()
|
||||
})
|
||||
return nil
|
||||
}
|
||||
|
||||
|
Reference in New Issue
Block a user