Backtick table name in generic orphan check (#20019) (#20037)

Backport #20019

- Resolves #20018
tokarchuk/v1.17
zeripath 3 years ago committed by GitHub
parent 2a48833f93
commit ab9fcb0cf4
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
  1. 4
      modules/doctor/dbconsistency.go

@ -201,10 +201,10 @@ func checkDBConsistency(ctx context.Context, logger log.Logger, autofix bool) er
"oauth2_authorization_code", "oauth2_grant", "oauth2_authorization_code.grant_id=oauth2_grant.id"),
// find stopwatches without existing user
genericOrphanCheck("Orphaned Stopwatches without existing User",
"stopwatch", "user", "stopwatch.user_id=user.id"),
"stopwatch", "user", "stopwatch.user_id=`user`.id"),
// find stopwatches without existing issue
genericOrphanCheck("Orphaned Stopwatches without existing Issue",
"stopwatch", "issue", "stopwatch.issue_id=issue.id"),
"stopwatch", "issue", "stopwatch.issue_id=`issue`.id"),
)
for _, c := range consistencyChecks {

Loading…
Cancel
Save