scheduler: fix linter errors

Fix errors reported by default golangci-lint linters
This commit is contained in:
Simone Gotti 2019-07-02 15:56:14 +02:00
parent e508993d93
commit f80cb15cd6
1 changed files with 5 additions and 5 deletions

View File

@ -190,6 +190,7 @@ func NewScheduler(c *config.Scheduler) (*Scheduler, error) {
} }
return &Scheduler{ return &Scheduler{
c: c,
runserviceClient: rsapi.NewClient(c.RunserviceURL), runserviceClient: rsapi.NewClient(c.RunserviceURL),
}, nil }, nil
} }
@ -198,9 +199,8 @@ func (s *Scheduler) Run(ctx context.Context) error {
go s.scheduleLoop(ctx) go s.scheduleLoop(ctx)
go s.approveLoop(ctx) go s.approveLoop(ctx)
select { <-ctx.Done()
case <-ctx.Done():
log.Infof("scheduler exiting") log.Infof("scheduler exiting")
return nil return nil
}
} }