Skip to content

Commit 07f94fa

Browse files
bakeemawaytoysjbgi
authored andcommitted
Fixed a bug in the NonEmptyList Semigroup implementation that resulted in the same NonEmptyList appended to itself.
1 parent 0ff3a9c commit 07f94fa

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

core/src/main/java/fj/Semigroup.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -534,7 +534,7 @@ public static <A> Semigroup<NonEmptyList<A>> nonEmptyListSemigroup() {
534534
return semigroupDef(new Definition<NonEmptyList<A>>() {
535535
@Override
536536
public NonEmptyList<A> append(NonEmptyList<A> a1, NonEmptyList<A> a2) {
537-
return a1.append(a1);
537+
return a1.append(a2);
538538
}
539539

540540
@Override

0 commit comments

Comments
 (0)