mirror of
https://github.com/goharbor/harbor.git
synced 2024-11-24 19:25:19 +01:00
fix: nil pointer dereference when failed to scan out the quota records from redis (#21046)
Signed-off-by: Liang Zheng <zhengliang0901@gmail.com>
This commit is contained in:
parent
ab3d3504fb
commit
de6c96be4c
@ -123,6 +123,7 @@ func flushQuota(ctx context.Context) {
|
||||
iter, err := cache.Default().Scan(ctx, "quota:*")
|
||||
if err != nil {
|
||||
log.Errorf("failed to scan out the quota records from redis")
|
||||
return
|
||||
}
|
||||
|
||||
for iter.Next(ctx) {
|
||||
|
Loading…
Reference in New Issue
Block a user