Skip to content

Commit

Permalink
Fix incorrect config property used in grants per doc warning threshold (
Browse files Browse the repository at this point in the history
  • Loading branch information
bbrks authored May 13, 2021
1 parent e68e379 commit 37c05f7
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion db/crud.go
Original file line number Diff line number Diff line change
Expand Up @@ -1915,7 +1915,7 @@ func (db *Database) checkDocChannelsAndGrantsLimits(docID string, channels base.
}

// Warn when grants are larger than a configured threshold
if grantThreshold := db.Options.UnsupportedOptions.WarningThresholds.ChannelsPerDoc; grantThreshold != nil {
if grantThreshold := db.Options.UnsupportedOptions.WarningThresholds.GrantsPerDoc; grantThreshold != nil {
grantCount := len(accessGrants) + len(roleGrants)
if uint32(grantCount) >= *grantThreshold {
db.DbStats.Database().WarnGrantsPerDocCount.Add(1)
Expand Down

0 comments on commit 37c05f7

Please sign in to comment.