From c3fe24c6e136b9be4c4b7c17c37d3d636421ed41 Mon Sep 17 00:00:00 2001 From: sbilge Date: Wed, 11 Dec 2024 11:51:13 +0000 Subject: [PATCH] accept empty content obj --- .../count_content_values/data_transform.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/metldata/builtin_transformations/count_content_values/data_transform.py b/src/metldata/builtin_transformations/count_content_values/data_transform.py index 0cc6353..c6d1f51 100644 --- a/src/metldata/builtin_transformations/count_content_values/data_transform.py +++ b/src/metldata/builtin_transformations/count_content_values/data_transform.py @@ -105,7 +105,7 @@ def transform_resource( ): """Apply the count content value transformation to each resource of a class.""" target_content = target_resource.get("content") - if not target_content: + if target_content is None: raise EvitableTransformationError() relation_target_ids = target_resource.get("relations", {}).get(relation_name)