Merge pull request #5243 from tokejepsen/bugfix/maya_arnold_prefix_none

This commit is contained in:
Milan Kolar 2023-07-06 12:01:54 +02:00 committed by GitHub
commit b538efdcdd
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -274,12 +274,14 @@ class ARenderProducts:
"Unsupported renderer {}".format(self.renderer)
)
# Note: When this attribute is never set (e.g. on maya launch) then
# this can return None even though it is a string attribute
prefix = self._get_attr(prefix_attr)
if not prefix:
# Fall back to scene name by default
log.debug("Image prefix not set, using <Scene>")
file_prefix = "<Scene>"
log.warning("Image prefix not set, using <Scene>")
prefix = "<Scene>"
return prefix