matthiasblaesing commented on code in PR #9489:
URL: https://github.com/apache/netbeans/pull/9489#discussion_r3685039764
##########
enterprise/web.jsf/src/org/netbeans/modules/web/jsf/api/editor/JSFBeanCache.java:
##########
@@ -51,41 +51,41 @@ public static List<FacesManagedBean> getBeans(Project
project) {
}
//<<<
- final List<FacesManagedBean> beans = new ArrayList<FacesManagedBean>();
+ final List<FacesManagedBean> beans = new ArrayList<>();
+
+ // managed beans have been removed in Faces 4.0
+ JsfVersion jsfVersion = JsfVersionUtils.forProject(project);
+ if (jsfVersion != null && jsfVersion.isAtLeast(JsfVersion.JSF_4_0)) {
Review Comment:
Shouldn't this be:
```suggestion
if (jsfVersion == null || jsfVersion.isAtLeast(JsfVersion.JSF_4_0)) {
```
so that this is consitent? I see:
- JsfELVariableResolver: `jsfVersion == null` -> no beans added
- WebBeansELVariableResolver: `jsfSupport == null` -> no beans returned
returning the empty list that is stored in `beans` seems to be in line with
that.
--
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: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]
For further information about the NetBeans mailing lists, visit:
https://cwiki.apache.org/confluence/display/NETBEANS/Mailing+lists