diff options
author | Campbell Barton <ideasman42@gmail.com> | 2018-07-07 12:32:40 +0300 |
---|---|---|
committer | Campbell Barton <ideasman42@gmail.com> | 2018-07-07 12:32:40 +0300 |
commit | 1f539cd7efbc0589f365bf3b1d21774e6e126ef4 (patch) | |
tree | 441bc47014f1ef32406578749c3c55c38ba2cf14 | |
parent | 0f1000ce0b296c1a6e4de3534dd3f3b51926167c (diff) | |
parent | 97cd8bfae19666554db17c42b3d2a7cfa16498f8 (diff) |
Merge branch 'master' into blender2.8
-rw-r--r-- | release/scripts/modules/bpy_extras/keyconfig_utils.py | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/release/scripts/modules/bpy_extras/keyconfig_utils.py b/release/scripts/modules/bpy_extras/keyconfig_utils.py index bf2c102458b..198fa787abe 100644 --- a/release/scripts/modules/bpy_extras/keyconfig_utils.py +++ b/release/scripts/modules/bpy_extras/keyconfig_utils.py @@ -239,9 +239,9 @@ def _export_properties(prefix, properties, kmi_id, lines=None): lines = [] def string_value(value): - if isinstance(value, str) or isinstance(value, bool) or isinstance(value, float) or isinstance(value, int): + if isinstance(value, (str, bool, float, int)): return repr(value) - elif getattr(value, '__len__', False): + elif hasattr(value, "__len__"): return repr(list(value)) print("Export key configuration: can't write ", value) |