Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Chore: Formatting fixes #283

Merged
merged 14 commits into from
Mar 27, 2024
Prev Previous commit
Next Next commit
use "not in" expression
  • Loading branch information
iLLiCiTiT committed Mar 27, 2024
commit b3aba193251e96806b206173700d81ba77e8fb49
Original file line number Diff line number Diff line change
Expand Up @@ -641,7 +641,7 @@ def _setStatus(self, status):
global gStatusTags

# Get a valid Tag object from the Global list of statuses
if not status in gStatusTags.keys():
if status not in gStatusTags.keys():
print("Status requested was not a valid Status string.")
return

Expand Down
10 changes: 7 additions & 3 deletions client/ayon_core/hosts/maya/api/lib.py
Original file line number Diff line number Diff line change
Expand Up @@ -2152,9 +2152,13 @@ def get_related_sets(node):
sets = cmds.ls(sets)

# Ignore `avalon.container`
sets = [s for s in sets if
not cmds.attributeQuery("id", node=s, exists=True) or
not cmds.getAttr("%s.id" % s) in ignored]
sets = [
s for s in sets
if (
not cmds.attributeQuery("id", node=s, exists=True)
or cmds.getAttr("%s.id" % s) not in ignored
)
]

# Exclude deformer sets (`type=2` for `maya.cmds.listSets`)
deformer_sets = cmds.listSets(object=node,
Expand Down