You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@solr.apache.org by "risdenk (via GitHub)" <gi...@apache.org> on 2023/03/29 14:17:13 UTC

[GitHub] [solr] risdenk commented on a diff in pull request #1500: remove-collections4

risdenk commented on code in PR #1500:
URL: https://github.com/apache/solr/pull/1500#discussion_r1152018700


##########
solr/core/src/java/org/apache/solr/packagemanager/PackageManager.java:
##########
@@ -307,15 +303,14 @@ public Map<String, SolrPackageInstance> getPackagesDeployedAsClusterLevelPlugins
       if (pluginMeta.klass.contains(":")) {
         String packageName = pluginMeta.klass.substring(0, pluginMeta.klass.indexOf(':'));
         packageVersions.put(packageName, pluginMeta.version);
-        packagePlugins.put(packageName, pluginMeta);
+        packagePlugins.computeIfAbsent(packageName, k -> new HashSet<>()).add(pluginMeta);
       }
     }
     Map<String, SolrPackageInstance> ret = new HashMap<>();
     for (String packageName : packageVersions.keySet()) {
-      if (StrUtils.isNullOrEmpty(packageName) == false
-          && // There can be an empty key, storing the version here
-          packageVersions.get(packageName)
-              != null) { // null means the package was undeployed from this package before
+      // There can be an empty key, storing the version here
+      // null means the package was undeployed from this package before
+      if (!StrUtils.isNullOrEmpty(packageName) && packageVersions.get(packageName) != null) {

Review Comment:
   Fixed in bf5a0744091e87c548bebb067ed5a4506662716e



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: issues-unsubscribe@solr.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscribe@solr.apache.org
For additional commands, e-mail: issues-help@solr.apache.org