Skip to content

Commit

Permalink
Avoid Groovy script crash
Browse files Browse the repository at this point in the history
  • Loading branch information
louwers committed Apr 3, 2024
1 parent a3a21e6 commit 4a211d2
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion gradle/artifact-settings.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,11 @@ def isSnapshot() {
}

private static def getReleaseVersion(String version) {
return version.substring(1)
if (version && version.length() > 1) {
return version.substring(1)
} else {
return "Unknown"
}
}

private static def getSnapshotVersion(String version) {
Expand Down

0 comments on commit 4a211d2

Please sign in to comment.