You are viewing a plain text version of this content. The canonical link for it is here.
Posted to notifications@netbeans.apache.org by GitBox <gi...@apache.org> on 2022/04/17 20:13:19 UTC

[GitHub] [netbeans] sdedic commented on a diff in pull request #3994: Fix GradleReport Notification and potential NPE on Gradle earlier, than 6.8

sdedic commented on code in PR #3994:
URL: https://github.com/apache/netbeans/pull/3994#discussion_r851799233


##########
extide/gradle/netbeans-gradle-tooling/src/main/java/org/netbeans/modules/gradle/tooling/NbProjectInfoBuilder.java:
##########
@@ -445,10 +445,14 @@ private void detectDependencies(NbProjectInfoModel model) {
                                 // do not bother with components that only select a variant, which is itself a component
                                 // TODO: represent as a special component type so the IDE shows it, but the IDE knows it is an abstract
                                 // intermediate with no artifact(s).
-                                if (rdr.getResolvedVariant() == null ||
-                                    !rdr.getResolvedVariant().getExternalVariant().isPresent()) {
+                                if (rdr.getResolvedVariant() == null) {
                                     componentIds.add(rdr.getSelected().getId().toString());
                                 }

Review Comment:
   I'd put the `sinceGradle` into `else` branch, so that executes just for `resolvedVariant != null` case.



-- 
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: notifications-unsubscribe@netbeans.apache.org

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


---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@netbeans.apache.org
For additional commands, e-mail: notifications-help@netbeans.apache.org

For further information about the NetBeans mailing lists, visit:
https://cwiki.apache.org/confluence/display/NETBEANS/Mailing+lists