org/ apache/wicket/util/lang/EnumeratedType.java method getValues never returns 
null
------------------------------------------------------------------------------------

                 Key: WICKET-3714
                 URL: https://issues.apache.org/jira/browse/WICKET-3714
             Project: Wicket
          Issue Type: Improvement
          Components: wicket-core
    Affects Versions: 1.5-RC4
         Environment: all
            Reporter: Richard Emberson
            Priority: Trivial


In EnumeratedType method readResolve:

  public Object readResolve() throws java.io.ObjectStreamException
  {
    EnumeratedType result = this;
    List<EnumeratedType> values = getValues(getClass());
    if (values != null)
    {
      for (EnumeratedType value : values)
      {
        if ((value.toString() != null) && 
value.toString().equals(this.toString()))
        {
          result = value;
          break;
        }
      }
    }
    return result;
  }

Note that the method getValues never returns null, so 

if (values != null) can be removed.

--
This message is automatically generated by JIRA.
For more information on JIRA, see: http://www.atlassian.com/software/jira

Reply via email to