mirror of
https://github.com/ynput/ayon-core.git
synced 2025-12-24 12:54:40 +01:00
remove unncessary product base type filters redefinitins
This commit is contained in:
parent
2f9cd88111
commit
4aefacaf44
1 changed files with 6 additions and 8 deletions
|
|
@ -127,14 +127,16 @@ class LoaderPlugin(list):
|
|||
"""
|
||||
|
||||
plugin_repre_names = cls.get_representations()
|
||||
plugin_product_types = cls.product_types
|
||||
plugin_product_base_types = cls.product_base_types
|
||||
|
||||
# If the product base type isn't defined on the loader plugin,
|
||||
# then we will use the product types.
|
||||
plugin_product_filter = plugin_product_base_types
|
||||
plugin_product_filter = cls.product_base_types
|
||||
if plugin_product_filter is None:
|
||||
plugin_product_filter = plugin_product_types
|
||||
plugin_product_filter = cls.product_types
|
||||
|
||||
if plugin_product_filter:
|
||||
plugin_product_filter = set(plugin_product_filter)
|
||||
|
||||
repre_entity = context.get("representation")
|
||||
product_entity = context["product"]
|
||||
|
||||
|
|
@ -164,7 +166,6 @@ class LoaderPlugin(list):
|
|||
if not cls.has_valid_extension(repre_entity):
|
||||
return False
|
||||
|
||||
plugin_product_types = set(plugin_product_types)
|
||||
product_type = product_entity.get("productType")
|
||||
product_base_type = product_entity.get("productBaseType")
|
||||
|
||||
|
|
@ -175,9 +176,6 @@ class LoaderPlugin(list):
|
|||
if product_filter is None:
|
||||
product_filter = product_type
|
||||
|
||||
plugin_product_filter = (
|
||||
plugin_product_base_types or plugin_product_types)
|
||||
|
||||
# If wildcard is used in product types or base types,
|
||||
# then we will consider the loader compatible with any product type.
|
||||
if "*" in plugin_product_filter:
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue