diff options
Diffstat (limited to 'src/eu/equalparts/cardbase/sorting')
-rw-r--r-- | src/eu/equalparts/cardbase/sorting/CardSorting.java | 4 |
1 files changed, 1 insertions, 3 deletions
diff --git a/src/eu/equalparts/cardbase/sorting/CardSorting.java b/src/eu/equalparts/cardbase/sorting/CardSorting.java index 04413b9..e7f7c96 100644 --- a/src/eu/equalparts/cardbase/sorting/CardSorting.java +++ b/src/eu/equalparts/cardbase/sorting/CardSorting.java @@ -10,11 +10,9 @@ public abstract class CardSorting { /** * @param cards * @param fieldName the name of the field by which to sort. - * @return an unmodifiable collection representing the cardbase sorted in the required order. * @throws NoSuchFieldException if the field provided is invalid. */ - public static List<Card> sortByField(List<Card> cards, String fieldName) throws NoSuchFieldException { + public static void sortByField(List<Card> cards, String fieldName) throws NoSuchFieldException { cards.sort(new CardComparator(Card.class.getDeclaredField(fieldName))); - return cards; } } |