mirror of
https://github.com/ynput/ayon-core.git
synced 2026-01-02 08:54:53 +01:00
OP-3908 - remove initialization of PhotoshopHost
Initialization might be expensive, use self.host instead.
This commit is contained in:
parent
0f4d15ec1c
commit
ec6654455e
2 changed files with 2 additions and 4 deletions
|
|
@ -123,7 +123,7 @@ class ImageCreator(Creator):
|
|||
|
||||
def remove_instances(self, instances):
|
||||
for instance in instances:
|
||||
PhotoshopHost().remove_instance(instance)
|
||||
self.host.remove_instance(instance)
|
||||
self._remove_instance_from_context(instance)
|
||||
|
||||
def get_default_variants(self):
|
||||
|
|
|
|||
|
|
@ -5,8 +5,6 @@ from openpype.pipeline import (
|
|||
CreatedInstance,
|
||||
legacy_io
|
||||
)
|
||||
from openpype.hosts.photoshop.api import PhotoshopHost
|
||||
|
||||
|
||||
class PSWorkfileCreator(AutoCreator):
|
||||
identifier = "workfile"
|
||||
|
|
@ -18,7 +16,7 @@ class PSWorkfileCreator(AutoCreator):
|
|||
return []
|
||||
|
||||
def collect_instances(self):
|
||||
for instance_data in PhotoshopHost().list_instances():
|
||||
for instance_data in self.host.list_instances():
|
||||
creator_id = instance_data.get("creator_identifier")
|
||||
if creator_id == self.identifier:
|
||||
subset_name = instance_data["subset"]
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue