This is an automated email from the ASF dual-hosted git repository.

ggregory pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/commons-text.git


The following commit(s) were added to refs/heads/master by this push:
     new 7a1a8a8  Simpler lambdas.
7a1a8a8 is described below

commit 7a1a8a8805a2868dee74a421c30f68880b49e9d7
Author: Gary Gregory <garydgreg...@gmail.com>
AuthorDate: Sun Jun 28 18:45:37 2020 -0400

    Simpler lambdas.
---
 src/main/java/org/apache/commons/text/lookup/FunctionStringLookup.java | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git 
a/src/main/java/org/apache/commons/text/lookup/FunctionStringLookup.java 
b/src/main/java/org/apache/commons/text/lookup/FunctionStringLookup.java
index 5fb234c..56e2c28 100644
--- a/src/main/java/org/apache/commons/text/lookup/FunctionStringLookup.java
+++ b/src/main/java/org/apache/commons/text/lookup/FunctionStringLookup.java
@@ -48,7 +48,7 @@ final class FunctionStringLookup<V> extends 
AbstractStringLookup {
      * @return a new instance backed by the given map.
      */
     static <V> FunctionStringLookup<V> on(final Map<String, V> map) {
-        return on(key -> map.get(key));
+        return on(map::get);
     }
 
     /**

Reply via email to