You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@myfaces.apache.org by "Paul Nicolucci (JIRA)" <de...@myfaces.apache.org> on 2018/01/10 18:54:00 UTC
[jira] [Commented] (MYFACES-4187) ResourceHandler.createResource
methods should throw NPE
[ https://issues.apache.org/jira/browse/MYFACES-4187?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16320842#comment-16320842 ]
Paul Nicolucci commented on MYFACES-4187:
-----------------------------------------
I'm writing a unit test and a fix for this. Should be trivial.
> ResourceHandler.createResource methods should throw NPE
> -------------------------------------------------------
>
> Key: MYFACES-4187
> URL: https://issues.apache.org/jira/browse/MYFACES-4187
> Project: MyFaces Core
> Issue Type: Bug
> Components: JSR-372
> Affects Versions: 2.3.0-beta
> Reporter: Paul Nicolucci
> Assignee: Paul Nicolucci
> Priority: Minor
> Fix For: 2.3.0
>
>
> ResourceHandler.createResource methods should throw NPE.
> Looking at the JavaDoc for the ResourceHandler we need to throw an NPE when the resourceName is null:
> https://javaee.github.io/javaee-spec/javadocs/javax/faces/application/ResourceHandler.html#createResource-java.lang.String-
> https://javaee.github.io/javaee-spec/javadocs/javax/faces/application/ResourceHandler.html#createResource-java.lang.String-java.lang.String-
> https://javaee.github.io/javaee-spec/javadocs/javax/faces/application/ResourceHandler.html#createResource-java.lang.String-java.lang.String-java.lang.String-
> Throws:
> NullPointerException - if resourceName is null.
> Currently our behavior looks to just return null which is incorrect according to the specification.
--
This message was sent by Atlassian JIRA
(v6.4.14#64029)