diff --git a/src/main/java/edu/harvard/iq/dataverse/search/SearchServiceBean.java b/src/main/java/edu/harvard/iq/dataverse/search/SearchServiceBean.java index 245f778da23..de75c88009f 100644 --- a/src/main/java/edu/harvard/iq/dataverse/search/SearchServiceBean.java +++ b/src/main/java/edu/harvard/iq/dataverse/search/SearchServiceBean.java @@ -332,7 +332,7 @@ public SolrQueryResponse search( // PERMISSION FILTER QUERY // ----------------------------------- String permissionFilterQuery = this.getPermissionFilterQuery(dataverseRequest, solrQuery, onlyDatatRelatedToMe, addFacets); - if (permissionFilterQuery != null) { + if (!StringUtils.isBlank(permissionFilterQuery)) { solrQuery.addFilterQuery(permissionFilterQuery); } @@ -1047,7 +1047,7 @@ private String getPermissionFilterQuery(DataverseRequest dataverseRequest, SolrQ // add joins on all the non-public groups that may exist for the // user: - // Authenticated users and GuestUser may be part of one or more groups; such + // Authenticated users, *and the GuestUser*, may be part of one or more groups; such // as IP Groups. groups = groupService.collectAncestors(groupService.groupsFor(dataverseRequest));