move version conflict logging for mark as complete to sqlstore package

This commit is contained in:
bergquist
2018-10-02 14:23:18 +02:00
parent 9d3659d30d
commit 67e5f62514
3 changed files with 12 additions and 19 deletions

View File

@@ -259,7 +259,10 @@ func SetAlertNotificationStateToCompleteCommand(ctx context.Context, cmd *m.SetA
}
if current.Version != version {
return m.ErrAlertNotificationStateVersionConflict
sqlog.Error(
`notification state out of sync. the notification
is marked as complete but has been modified between
set as pending and completion.`, "notifierId", current.NotifierId)
}
return nil