From d8708d62fa3b69a94dfde9e606c9c7b5d8c36b66 Mon Sep 17 00:00:00 2001 From: Denis Zhdanov Date: Sat, 28 Oct 2023 15:48:26 +0800 Subject: [PATCH] corrected mandatory base gradle version property checking --- .../oss/gradle/dist/CustomGradleDistributionPlugin.kt | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/main/kotlin/tech/harmonysoft/oss/gradle/dist/CustomGradleDistributionPlugin.kt b/src/main/kotlin/tech/harmonysoft/oss/gradle/dist/CustomGradleDistributionPlugin.kt index 4065dcc..acc99c1 100644 --- a/src/main/kotlin/tech/harmonysoft/oss/gradle/dist/CustomGradleDistributionPlugin.kt +++ b/src/main/kotlin/tech/harmonysoft/oss/gradle/dist/CustomGradleDistributionPlugin.kt @@ -61,7 +61,7 @@ class CustomGradleDistributionPlugin : Plugin { } private fun validateGradleVersion(extension: CustomGradleDistExtension) { - if (!extension.gradleVersion.isPresent && extension.gradleVersion.get().isBlank()) { + if (!extension.gradleVersion.isPresent || extension.gradleVersion.get().isBlank()) { throw IllegalStateException( """ can not build custom gradle distribution - base gradle version is undefined. Please specify it like below: