From 7edba4436636a9413d8b8b79ad96f3730ae90b6a Mon Sep 17 00:00:00 2001 From: 2bllw8 <2bllw8@gmail.com> Date: Fri, 15 Oct 2021 16:03:47 +0200 Subject: [PATCH] Version 2.1.0 --- README.md | 13 +++++-------- lib/build.gradle | 2 +- 2 files changed, 6 insertions(+), 9 deletions(-) diff --git a/README.md b/README.md index 901523f..37f9ec3 100644 --- a/README.md +++ b/README.md @@ -20,7 +20,7 @@ While `Either` is right–biased, it is possible to operate on the left values b The latest release is available on [Maven Central](https://search.maven.org/artifact/io.github.2bllw8/either/2.0.0/jar). ```groovy -implementation 'io.github.2bllw8:either:2.0.0' +implementation 'io.github.2bllw8:either:2.1.0' ``` ## Usage @@ -49,13 +49,10 @@ public class Main { for (int i = 0; i < results.size(); i++) { final String arg = args[i]; - final Either either = results.get(i); - if (either.isRight()) { - either.forEach(x -> System.out.println(arg + " -> " + x)); - } else { - either.left().forEach(x -> System.err.println("Error occurred for '" - + arg + "': " + x)); - } + results.get(i).forEach( + left -> System.err.println( + "Error occurred for '" + arg + "': " + left), + right -> System.out.println(arg + " -> " + right)); } } } diff --git a/lib/build.gradle b/lib/build.gradle index 522e3e1..638f569 100644 --- a/lib/build.gradle +++ b/lib/build.gradle @@ -28,7 +28,7 @@ pmd { archivesBaseName = rootProject.name group = 'exe.bbllw8' -version = '2.0.0' +version = '2.1.0' javadoc { options.memberLevel = JavadocMemberLevel.PUBLIC