More PEP8 compliance

This commit is contained in:
Simone Barbieri 2020-03-20 16:46:45 +00:00
parent a3d025f784
commit 40cf778f10
7 changed files with 16 additions and 13 deletions

View file

@ -27,8 +27,8 @@ class CreateAction(Creator):
if (self.options or {}).get("useSelection"):
for obj in lib.get_selection():
if (obj.animation_data is not None and
obj.animation_data.action is not None):
if (obj.animation_data is not None
and obj.animation_data.action is not None):
empty_obj = bpy.data.objects.new(name=name,
object_data=None)

View file

@ -175,7 +175,7 @@ class BlendActionLoader(pype.blender.plugin.AssetLoader):
strips = []
for obj in collection_metadata["objects"]:
# Get all the strips that use the action
arm_objs = [
arm for arm in bpy.data.objects if arm.type == 'ARMATURE']

View file

@ -23,8 +23,8 @@ class CollectAction(pyblish.api.ContextPlugin):
"""
for collection in bpy.data.collections:
avalon_prop = collection.get(AVALON_PROPERTY) or dict()
if (avalon_prop.get('family') == 'action' and
not avalon_prop.get('representation')):
if (avalon_prop.get('family') == 'action'
and not avalon_prop.get('representation')):
yield collection
def process(self, context):

View file

@ -18,13 +18,13 @@ class CollectAnimation(pyblish.api.ContextPlugin):
"""Return all 'animation' collections.
Check if the family is 'animation' and if it doesn't have the
representation set. If the representation is set, it is a loaded
representation set. If the representation is set, it is a loaded
animation and we don't want to publish it.
"""
for collection in bpy.data.collections:
avalon_prop = collection.get(AVALON_PROPERTY) or dict()
if (avalon_prop.get('family') == 'animation' and
not avalon_prop.get('representation')):
if (avalon_prop.get('family') == 'animation'
and not avalon_prop.get('representation')):
yield collection
def process(self, context):

View file

@ -23,8 +23,8 @@ class CollectModel(pyblish.api.ContextPlugin):
"""
for collection in bpy.data.collections:
avalon_prop = collection.get(AVALON_PROPERTY) or dict()
if (avalon_prop.get('family') == 'model' and
not avalon_prop.get('representation')):
if (avalon_prop.get('family') == 'model'
and not avalon_prop.get('representation')):
yield collection
def process(self, context):

View file

@ -23,8 +23,8 @@ class CollectRig(pyblish.api.ContextPlugin):
"""
for collection in bpy.data.collections:
avalon_prop = collection.get(AVALON_PROPERTY) or dict()
if (avalon_prop.get('family') == 'rig' and
not avalon_prop.get('representation')):
if (avalon_prop.get('family') == 'rig'
and not avalon_prop.get('representation')):
yield collection
def process(self, context):