From 28aa515a964421abba8cefd2f43ef2bf75fe47c5 Mon Sep 17 00:00:00 2001 From: Bryan Newbold Date: Thu, 17 Dec 2020 19:22:26 -0800 Subject: bug fix: is_preserved should always be bool --- python/fatcat_tools/transforms/elasticsearch.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'python') diff --git a/python/fatcat_tools/transforms/elasticsearch.py b/python/fatcat_tools/transforms/elasticsearch.py index ad4b7722..db860a09 100644 --- a/python/fatcat_tools/transforms/elasticsearch.py +++ b/python/fatcat_tools/transforms/elasticsearch.py @@ -217,8 +217,8 @@ def release_to_elasticsearch(entity: ReleaseEntity, force_bool: bool = True) -> t[k] = bool(t[k]) t['in_ia'] = bool(t['in_ia']) - t['is_preserved'] = ( - bool(t['is_preserved']) + t['is_preserved'] = bool( + t['is_preserved'] or t['in_ia'] or t['in_kbart'] or t['in_jstor'] -- cgit v1.2.3