You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@isis.apache.org by "Dan Haywood (JIRA)" <ji...@apache.org> on 2013/02/03 16:00:15 UTC

[jira] [Resolved] (ISIS-324) ToDoItem.compare compares against itself.

     [ https://issues.apache.org/jira/browse/ISIS-324?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Dan Haywood resolved ISIS-324.
------------------------------

    Resolution: Fixed
    
> ToDoItem.compare compares against itself.
> -----------------------------------------
>
>                 Key: ISIS-324
>                 URL: https://issues.apache.org/jira/browse/ISIS-324
>             Project: Isis
>          Issue Type: Bug
>          Components: Archetypes
>    Affects Versions: archetype-wrj-1.0.2
>            Reporter: Minto van der Sluis
>            Assignee: Dan Haywood
>            Priority: Minor
>             Fix For: archetype-wrj-1.0.3
>
>
> final statements in the compare method compares with itself:
>         if (getDueBy() == null && other.getDueBy() == null || getDueBy().equals(this.getDueBy())) {
>             return getDescription().compareTo(other.getDescription());
>         }
>         return getDueBy().compareTo(getDueBy());
> Should be:
>         if (getDueBy() == null && other.getDueBy() == null || getDueBy().equals(other.getDueBy())) {
>             return getDescription().compareTo(other.getDescription());
>         }
>         return getDueBy().compareTo(other.getDueBy());

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira