diff options
-rw-r--r-- | .pylintrc | 1 | ||||
-rw-r--r-- | buildstream/_yaml.py | 3 |
2 files changed, 1 insertions, 3 deletions
@@ -112,7 +112,6 @@ disable=##################################### # Messages that report warnings which should be addressed # ########################################################### - consider-merging-isinstance, dangerous-default-value, global-statement, len-as-condition, diff --git a/buildstream/_yaml.py b/buildstream/_yaml.py index c771e1b82..2e29f5e18 100644 --- a/buildstream/_yaml.py +++ b/buildstream/_yaml.py @@ -355,8 +355,7 @@ def node_get(node, expected_type, key, indices=[], default_value=None): raise ValueError() elif not (expected_type == list or expected_type == dict or - isinstance(value, list) or - isinstance(value, dict)): + isinstance(value, (list, dict))): value = expected_type(value) else: raise ValueError() |