From 1a347d3cdb91de1444c76a957faf124802887f4b Mon Sep 17 00:00:00 2001 From: alec_dev Date: Tue, 17 Dec 2024 17:09:32 -0600 Subject: [PATCH] filter out nulls from cog_co_ids in preps_available_rs --- specifyweb/interactions/views.py | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/specifyweb/interactions/views.py b/specifyweb/interactions/views.py index 1b120b7213f..6ddb21ea0c9 100644 --- a/specifyweb/interactions/views.py +++ b/specifyweb/interactions/views.py @@ -99,10 +99,9 @@ def preps_available_rs(request, recordset_id): # Get consolidated CO ids if the recordset is a COG rs = Recordset.objects.filter(id=recordset_id).first() cog_co_ids = get_co_ids_from_shared_cog_rs(rs) + cog_co_ids = [co_id for co_id in cog_co_ids if co_id is not None] # cog_co_ids = set() cog_co_ids_str = ','.join(map(str, cog_co_ids)) if cog_co_ids else 'NULL' - if cog_co_ids_str is None or cog_co_ids_str == '': - cog_co_ids_str = 'NULL' cursor = connection.cursor()