From ac5317bef9d318d2257fd2aab8e16800978a607d Mon Sep 17 00:00:00 2001 From: John Chilton Date: Tue, 28 Jan 2014 10:34:44 -0600 Subject: [PATCH] Yet another fix for 714f5b1 (history contents API)... Fix history contents API when setting visible and/or deleted. --- lib/galaxy/model/__init__.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/lib/galaxy/model/__init__.py b/lib/galaxy/model/__init__.py index 6769e741475..4cdcf5adcaa 100644 --- a/lib/galaxy/model/__init__.py +++ b/lib/galaxy/model/__init__.py @@ -926,10 +926,10 @@ class History( object, Dictifiable, UsesAnnotations ): query = query.order_by( HistoryDatasetAssociation.table.c.hid.asc() ) deleted = galaxy.util.string_as_bool_or_none( kwds.get( 'deleted', None ) ) if deleted is not None: - query = query.filter( HistoryDatasetAssociation.deleted == bool( kwds['deleted'] ) ) + query = query.filter( HistoryDatasetAssociation.deleted == deleted ) visible = galaxy.util.string_as_bool_or_none( kwds.get( 'visible', None ) ) if visible is not None: - query = query.filter( HistoryDatasetAssociation.visible == bool( kwds['visible'] ) ) + query = query.filter( HistoryDatasetAssociation.visible == visible ) if 'ids' in kwds: ids = kwds['ids'] max_in_filter_length = kwds.get('max_in_filter_length', MAX_IN_FILTER_LENGTH)