From ae6cf4ebb8d555135e405fe2fe92b35c63d8c6ae Mon Sep 17 00:00:00 2001 From: Philip Durbin Date: Thu, 30 May 2024 14:53:59 -0400 Subject: [PATCH] no-op code cleanup, correct case of publicObject_b #10554 --- .../edu/harvard/iq/dataverse/search/SearchServiceBean.java | 4 ++-- .../java/edu/harvard/iq/dataverse/settings/FeatureFlags.java | 4 ++-- 2 files changed, 4 insertions(+), 4 deletions(-) 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 8f9fee46fcc..3d6a563da58 100644 --- a/src/main/java/edu/harvard/iq/dataverse/search/SearchServiceBean.java +++ b/src/main/java/edu/harvard/iq/dataverse/search/SearchServiceBean.java @@ -1063,7 +1063,7 @@ private String getPermissionFilterQuery(DataverseRequest dataverseRequest, SolrQ StringBuilder sbgroups = new StringBuilder(); // All users, guests and authenticated, should see all the - // documents marked as PublicObject_b:true, at least: + // documents marked as publicObject_b:true, at least: sb.append(SearchFields.PUBLIC_OBJECT + ":" + true); // One or more groups *may* also be available for this user. Once again, @@ -1161,7 +1161,7 @@ private String getPermissionFilterQuery(DataverseRequest dataverseRequest, SolrQ * @todo rename this from publicPlusUserPrivateGroup. Confusing */ // safe default: public only - String publicPlusUserPrivateGroup = publicOnly; + String publicPlusUserPrivateGroup = publicOnly; // + (onlyDatatRelatedToMe ? "" : (publicOnly + " OR ")) // + "{!join from=" + SearchFields.GROUPS + " to=" + SearchFields.PERMS + "}id:" + IndexServiceBean.getGroupPerUserPrefix() + au.getId() + ")"; diff --git a/src/main/java/edu/harvard/iq/dataverse/settings/FeatureFlags.java b/src/main/java/edu/harvard/iq/dataverse/settings/FeatureFlags.java index cb0820c354a..14a7ab86f22 100644 --- a/src/main/java/edu/harvard/iq/dataverse/settings/FeatureFlags.java +++ b/src/main/java/edu/harvard/iq/dataverse/settings/FeatureFlags.java @@ -39,7 +39,7 @@ public enum FeatureFlags { /** * For published (public) objects, don't use a join when searching Solr. * Experimental! Requires a reindex with the following feature flag enabled, - * in order to add the boolean PublicObject_b:true field to all the public + * in order to add the boolean publicObject_b:true field to all the public * Solr documents. * * @apiNote Raise flag by setting @@ -48,7 +48,7 @@ public enum FeatureFlags { */ AVOID_EXPENSIVE_SOLR_JOIN("avoid-expensive-solr-join"), /** - * With this flag enabled, the boolean field PublicObject_b:true will be + * With this flag enabled, the boolean field publicObject_b:true will be * added to all the indexed Solr documents for publicly-available collections, * datasets and files. This flag makes it possible to rely on it in searches, * instead of the very expensive join (the feature flag above).