fix lint errors (#1171)

This commit is contained in:
Travis Groth 2020-07-31 00:00:06 -04:00 committed by GitHub
parent aa8ba35332
commit aab9ec413e
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
2 changed files with 5 additions and 5 deletions

View file

@ -11,11 +11,9 @@ const (
ServiceAuthenticate = "authenticate"
// ServiceCache represents running the cache service component
ServiceCache = "cache"
// RedisName is the name of the redis storage backend
// StorageRedisName is the name of the redis storage backend
StorageRedisName = "redis"
// InMemoryName is the name of the in-memory storage backend
// StorageInMemoryName is the name of the in-memory storage backend
StorageInMemoryName = "memory"
)

View file

@ -209,7 +209,9 @@ func (db *DB) ClearDeleted(ctx context.Context, cutoff time.Time) {
_, span := trace.StartSpan(ctx, "databroker.redis.ClearDeleted")
defer span.End()
var opErr error
defer recordOperation(ctx, time.Now(), "clear_deleted", opErr)
defer func(startTime time.Time) {
recordOperation(ctx, startTime, "clear_deleted", opErr)
}(time.Now())
defer c.Close()
ids, _ := redis.Strings(c.Do("SMEMBERS", db.deletedSet))