aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--generalresearch/managers/thl/product.py8
-rw-r--r--pyproject.toml2
2 files changed, 4 insertions, 6 deletions
diff --git a/generalresearch/managers/thl/product.py b/generalresearch/managers/thl/product.py
index fb893c6..eacec5b 100644
--- a/generalresearch/managers/thl/product.py
+++ b/generalresearch/managers/thl/product.py
@@ -436,11 +436,9 @@ class ProductManager(PostgresManager):
params = {}
filters = []
identifiers = [product_uuids, business_uuids, team_uuids]
- assert sum([bool(x) for x in identifiers]) == 1, (
- "Must provide exactly one set of identifiers"
- )
- identifier = next(x for x in identifiers if x)
- assert all(is_valid_uuid(v) for v in identifier), "invalid uuid"
+ for identifier in identifiers:
+ if identifier is not None:
+ assert all(is_valid_uuid(v) for v in identifier), "invalid uuid"
if product_uuids is not None:
filters.append("bp.id = ANY(%(product_uuids)s)")
diff --git a/pyproject.toml b/pyproject.toml
index c165cd1..5b4e68f 100644
--- a/pyproject.toml
+++ b/pyproject.toml
@@ -4,7 +4,7 @@ build-backend = "setuptools.build_meta"
[project]
name = "generalresearch"
-version = "3.8.7"
+version = "3.8.8"
description = "Python Utilities for General Research"
readme = "README.md"
requires-python = ">=3.14"