chore: move content update to else statement

This commit is contained in:
Stefan Martinov 2022-05-10 17:11:49 +02:00
parent 19a4d688ae
commit 2c44c41701

View File

@ -38,6 +38,7 @@ func (repo *Repo) updateRoutine() {
log.Error("Content update failed", zap.Error(err))
status.M.UpdatesFailedCounter.WithLabelValues().Inc()
} else {
log.Info("Content update success")
status.M.UpdatesCompletedCounter.WithLabelValues().Inc()
}
@ -46,7 +47,6 @@ func (repo *Repo) updateRoutine() {
err: err,
}
log.Info("Content update completed")
status.M.UpdateDuration.WithLabelValues().Observe(time.Since(start).Seconds())
}
}