Skip to content

Commit

Permalink
Fix agent stop func
Browse files Browse the repository at this point in the history
  • Loading branch information
Victor Castell committed Aug 25, 2018
1 parent 0618dac commit 05744ca
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion dkron/agent.go
Original file line number Diff line number Diff line change
Expand Up @@ -97,7 +97,9 @@ func (a *Agent) Start() error {
}

func (a *Agent) Stop() error {
a.candidate.Stop()
if a.config.Server {
a.candidate.Stop()
}

if err := a.serf.Leave(); err != nil {
return err
Expand Down

0 comments on commit 05744ca

Please sign in to comment.