auth_proxy: non-negative cache TTL (#17495)

fixes setex error with redis on #17377

(cherry picked from commit 826d33ea37)
This commit is contained in:
Kyle Brandt
2019-06-17 12:07:51 +01:00
committed by gotjosh
parent 07540dfdce
commit 9a93382348
+1 -1
View File
@@ -311,7 +311,7 @@ func (auth *AuthProxy) Remember(id int64) *Error {
return nil
}
expiration := time.Duration(-auth.cacheTTL) * time.Minute
expiration := time.Duration(auth.cacheTTL) * time.Minute
err = auth.store.Set(key, id, expiration)
if err != nil {