From: Kefu Chai Date: Fri, 2 Feb 2018 08:25:26 +0000 (+0800) Subject: mgr/mgr_module: do not offer empty default value for choose_args X-Git-Tag: v13.0.2~360^2 X-Git-Url: http://git-server-git.apps.pok.os.sepia.ceph.com/?a=commitdiff_plain;h=refs%2Fpull%2F20258%2Fhead;p=ceph.git mgr/mgr_module: do not offer empty default value for choose_args as it should be always available. this also silence a pep8 warning. Signed-off-by: Kefu Chai --- diff --git a/src/pybind/mgr/mgr_module.py b/src/pybind/mgr/mgr_module.py index 1e36c27ffa32..2211df8037b7 100644 --- a/src/pybind/mgr/mgr_module.py +++ b/src/pybind/mgr/mgr_module.py @@ -149,7 +149,7 @@ class CRUSHMap(ceph_module.BasePyCRUSH): @staticmethod def get_default_choose_args(dump): - return dump.get('choose_args', {}).get(CRUSHMap.DEFAULT_CHOOSE_ARGS, []) + return dump.get('choose_args').get(CRUSHMap.DEFAULT_CHOOSE_ARGS, []) class MgrStandbyModule(ceph_module.BaseMgrStandbyModule):