From 43de9a34e341796c5023ba53624296a529b4d59d Mon Sep 17 00:00:00 2001 From: Brian Demers Date: Mon, 8 Jun 2020 13:59:41 -0400 Subject: [PATCH] Add parameterized return type to Maps.and() (#597) Fixes: #591 --- CHANGELOG.md | 6 ++++++ api/src/main/java/io/jsonwebtoken/lang/Maps.java | 4 ++-- 2 files changed, 8 insertions(+), 2 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 5a91d9b8..aba7e600 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,5 +1,11 @@ ## Release Notes +### 0.12.0 + +This minor release: + +* Adds missing parameter type to `Maps.add()`, which removes an unchecked type warning. + ### 0.11.1 This patch release: diff --git a/api/src/main/java/io/jsonwebtoken/lang/Maps.java b/api/src/main/java/io/jsonwebtoken/lang/Maps.java index 96460e0d..f96e4cb3 100644 --- a/api/src/main/java/io/jsonwebtoken/lang/Maps.java +++ b/api/src/main/java/io/jsonwebtoken/lang/Maps.java @@ -63,7 +63,7 @@ public final class Maps { * @param value the value of map entry to be added * @return the current MapBuilder to allow for method chaining. */ - MapBuilder and(K key, V value); + MapBuilder and(K key, V value); /** * Returns a the resulting Map object from this MapBuilder. @@ -76,7 +76,7 @@ public final class Maps { private final Map data = new HashMap<>(); - public MapBuilder and(K key, V value) { + public MapBuilder and(K key, V value) { data.put(key, value); return this; }