boolean (JpsDependencyElement dependency) { boolean isJavaSdk = dependency instanceof JpsSdkDependency && ((JpsSdkDependency)dependency).getSdkType().equals(JpsJavaSdkType.INSTANCE); if (myModule.equals(dependency.getContainingModule()) && isJavaSdk) { mySdkFound = true; } return !mySdkFound && !isJavaSdk; }