diff options
author | Campbell Barton <ideasman42@gmail.com> | 2012-01-02 20:18:39 +0400 |
---|---|---|
committer | Campbell Barton <ideasman42@gmail.com> | 2012-01-02 20:18:39 +0400 |
commit | 77bdef4d2251a378c178ab571f3ffd3add39ae91 (patch) | |
tree | fd449a3d6f0c3de4185ad2f825dfa89b84b2e391 /release/scripts/startup/bl_operators/anim.py | |
parent | 2077b7e3b7bafde69490419d565fa5e51f4f4cde (diff) |
py scripts - replace bad uses of len(),
checking if the collection is True is faster since it only checks if it has at least one item, rather then going over all items.
Diffstat (limited to 'release/scripts/startup/bl_operators/anim.py')
-rw-r--r-- | release/scripts/startup/bl_operators/anim.py | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/release/scripts/startup/bl_operators/anim.py b/release/scripts/startup/bl_operators/anim.py index 01103aede0d..29e8a396088 100644 --- a/release/scripts/startup/bl_operators/anim.py +++ b/release/scripts/startup/bl_operators/anim.py @@ -239,7 +239,7 @@ class ClearUselessActions(Operator): @classmethod def poll(cls, context): - return len(bpy.data.actions) != 0 + return bool(bpy.data.actions) def execute(self, context): removed = 0 |