diff --git a/CHANGELOG.md b/CHANGELOG.md index b71ad24b2..2b9203ebc 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -11,12 +11,18 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0 ### Changed -## [1.0.3] - 2023-02-19 +## [1.0.4] - 2023-02-22 ### Changed - Added contentLength property to RequestInformation to facilitate in setting the content length of the Okhttp3 RequestBody object within the OkhttpRequestAdapter. +## [1.0.3] - 2024-02-21 + +### Changed + +- Fixed compatibility with Java 8 by replacing `isBlank` with `Compatibility.isBlank` + ## [1.0.2] - 2024-02-13 ### Changed diff --git a/README.md b/README.md index fde6c081b..0ca55c4a0 100644 --- a/README.md +++ b/README.md @@ -21,13 +21,13 @@ Read more about Kiota [here](https://github.com/microsoft/kiota/blob/main/README In `build.gradle` in the `dependencies` section: ```Groovy -implementation 'com.microsoft.kiota:microsoft-kiota-abstractions:1.0.0' -implementation 'com.microsoft.kiota:microsoft-kiota-authentication-azure:1.0.0' -implementation 'com.microsoft.kiota:microsoft-kiota-http-okHttp:1.0.0' -implementation 'com.microsoft.kiota:microsoft-kiota-serialization-json:1.0.0' -implementation 'com.microsoft.kiota:microsoft-kiota-serialization-text:1.0.0' -implementation 'com.microsoft.kiota:microsoft-kiota-serialization-form:1.0.0' -implementation 'com.microsoft.kiota:microsoft-kiota-serialization-multipart:1.0.0' +implementation 'com.microsoft.kiota:microsoft-kiota-abstractions:1.0.3' +implementation 'com.microsoft.kiota:microsoft-kiota-authentication-azure:1.0.3' +implementation 'com.microsoft.kiota:microsoft-kiota-http-okHttp:1.0.3' +implementation 'com.microsoft.kiota:microsoft-kiota-serialization-json:1.0.3' +implementation 'com.microsoft.kiota:microsoft-kiota-serialization-text:1.0.3' +implementation 'com.microsoft.kiota:microsoft-kiota-serialization-form:1.0.3' +implementation 'com.microsoft.kiota:microsoft-kiota-serialization-multipart:1.0.3' ``` ### With Maven: @@ -38,37 +38,37 @@ In `pom.xml` in the `dependencies` section: com.microsoft.kiota microsoft-kiota-abstractions - 1.0.0 + 1.0.3 com.microsoft.kiota microsoft-kiota-authentication-azure - 1.0.0 + 1.0.3 com.microsoft.kiota microsoft-kiota-http-okHttp - 1.0.0 + 1.0.3 com.microsoft.kiota microsoft-kiota-serialization-json - 1.0.0 + 1.0.3 com.microsoft.kiota microsoft-kiota-serialization-text - 1.0.0 + 1.0.3 com.microsoft.kiota microsoft-kiota-serialization-form - 1.0.0 + 1.0.3 com.microsoft.kiota microsoft-kiota-serialization-multipart - 1.0.0 + 1.0.3 ``` diff --git a/components/http/okHttp/src/main/java/com/microsoft/kiota/http/middleware/ParametersNameDecodingHandler.java b/components/http/okHttp/src/main/java/com/microsoft/kiota/http/middleware/ParametersNameDecodingHandler.java index 0d21e0b48..0cab034c9 100644 --- a/components/http/okHttp/src/main/java/com/microsoft/kiota/http/middleware/ParametersNameDecodingHandler.java +++ b/components/http/okHttp/src/main/java/com/microsoft/kiota/http/middleware/ParametersNameDecodingHandler.java @@ -1,5 +1,6 @@ package com.microsoft.kiota.http.middleware; +import com.microsoft.kiota.Compatibility; import com.microsoft.kiota.http.middleware.options.ParametersNameDecodingOption; import io.opentelemetry.api.trace.Span; @@ -107,7 +108,7 @@ public ParametersNameDecodingHandler(@Nonnull final ParametersNameDecodingOption @Nullable final String original, @Nonnull final char[] charactersToDecode) { Objects.requireNonNull(charactersToDecode); - if (original == null || original.isBlank() || charactersToDecode.length == 0) { + if (original == null || Compatibility.isBlank(original) || charactersToDecode.length == 0) { return ""; } @@ -152,7 +153,7 @@ public ParametersNameDecodingHandler(@Nonnull final ParametersNameDecodingOption return toDecode.stream() .map( tuple -> - tuple.getKey().isBlank() + Compatibility.isBlank(tuple.getKey()) ? tuple.getValue() : tuple.getValue() + "=" + tuple.getKey()) .collect(Collectors.joining("&"));