Skip to content

Commit

Permalink
fix keeper bugs
Browse files Browse the repository at this point in the history
  • Loading branch information
Wenne committed Dec 6, 2023
1 parent adf448f commit 33f2892
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion keeper/mysql/mysql.go
Original file line number Diff line number Diff line change
Expand Up @@ -305,7 +305,7 @@ func (k *Keeper) campaign() error {
func (k *Keeper) continueLeader() error {
return k.transaction(func(tx *gorm.DB) error {
update := tx.Model(&Election{}).
Where("id = ?", LeaderKey).Where("worker_key = ?", k.WorkerKey()).
Where("id = ?", LeaderKey).
Update("updated_at", time.Now())
if update.Error != nil {
log.Errorf("update failed: %s", update.Error)
Expand Down

0 comments on commit 33f2892

Please sign in to comment.