From a3ba8188d7a561b7c1d570fc249929ed2eec5639 Mon Sep 17 00:00:00 2001 From: Harshavardhana Date: Mon, 12 Oct 2020 14:23:44 -0700 Subject: [PATCH] fix: allow locker to be niladic --- cmd/lock-rest-server.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/cmd/lock-rest-server.go b/cmd/lock-rest-server.go index 68ec14a94..dc47518c3 100644 --- a/cmd/lock-rest-server.go +++ b/cmd/lock-rest-server.go @@ -281,7 +281,7 @@ func lockMaintenance(ctx context.Context, interval time.Duration) error { // we only look for ownership of locks from endpoints // on first zone. for _, c := range allLockersFn() { - if !c.IsOnline() { + if !c.IsOnline() || c == nil { updateNlocks(nlripsMap, nlrip.name, nlrip.lri.Writer) continue }