mirror of
https://github.com/ynput/ayon-core.git
synced 2026-01-01 08:24:53 +01:00
apply setting fix so it works in deprecated and new configuration
This commit is contained in:
parent
0953dc65cc
commit
4c90065f43
1 changed files with 7 additions and 6 deletions
|
|
@ -39,13 +39,14 @@ class ValidateCorrectAssetContext(
|
|||
"""Apply deprecated settings from project settings.
|
||||
"""
|
||||
nuke_publish = project_settings["nuke"]["publish"]
|
||||
if "ValidateCorrectAssetName" not in nuke_publish:
|
||||
return
|
||||
if "ValidateCorrectAssetName" in nuke_publish:
|
||||
settings = nuke_publish["ValidateCorrectAssetName"]
|
||||
else:
|
||||
settings = nuke_publish["ValidateCorrectAssetContext"]
|
||||
|
||||
deprecated_setting = nuke_publish["ValidateCorrectAssetName"]
|
||||
cls.enabled = deprecated_setting["enabled"]
|
||||
cls.optional = deprecated_setting["optional"]
|
||||
cls.active = deprecated_setting["active"]
|
||||
cls.enabled = settings["enabled"]
|
||||
cls.optional = settings["optional"]
|
||||
cls.active = settings["active"]
|
||||
|
||||
def process(self, instance):
|
||||
if not self.is_active(instance.data):
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue