From f9d291b5755520feca393c7fca964de999a6e90a Mon Sep 17 00:00:00 2001 From: Sage Weil Date: Wed, 2 Jun 2021 14:43:52 -0400 Subject: [PATCH] mgr/nfs/cluster: fix type error Signed-off-by: Sage Weil --- src/pybind/mgr/nfs/cluster.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/pybind/mgr/nfs/cluster.py b/src/pybind/mgr/nfs/cluster.py index 232b590b44a..63f55dd6c96 100644 --- a/src/pybind/mgr/nfs/cluster.py +++ b/src/pybind/mgr/nfs/cluster.py @@ -161,7 +161,7 @@ class NFSCluster: else: c = self.mgr.get_hosts() orchestrator.raise_if_exception(c) - hosts = [h for h in c.result + hosts = [h for h in c.result or [] if h.hostname == cluster.hostname] if hosts: ip = resolve_ip(hosts[0].addr) -- 2.39.5