fix how context information is returned

This commit is contained in:
Jakub Trllo 2023-02-15 10:43:20 +01:00
parent bd8f68c6e9
commit d26d9083ce

View file

@ -124,8 +124,11 @@ class TVPaintHost(HostBase, IWorkfileHost, ILoadHost, IPublishHost):
if not context:
return get_global_context()
if "project_name" in context:
return context
# This is legacy way how context was stored
return {
"project_name": context["project"],
"project_name": context.get("project"),
"asset_name": context.get("asset"),
"task_name": context.get("task")
}