File tree Expand file tree Collapse file tree 1 file changed +5
-4
lines changed
src/main/groovy/net/minecraftforge/gradleutils/changelog Expand file tree Collapse file tree 1 file changed +5
-4
lines changed Original file line number Diff line number Diff line change @@ -97,11 +97,11 @@ class ChangelogUtils {
9797 if (versionMap. containsKey(commitHash)) {
9898 def version = versionMap. get(commitHash);
9999 if (tagMap. containsKey(commitHash) && ! justText) {
100- commitHeader+ = " [${ version.padRight(primaryVersionPrefixLengthMap.get (currentPrimaryVersion))} ]($repositoryUrl /tree/$version )"
100+ commitHeader+ = " [${ version.padRight(primaryVersionPrefixLengthMap.getOrDefault (currentPrimaryVersion, 0 ))} ]($repositoryUrl /tree/$version )"
101101 }
102102 else
103103 {
104- commitHeader+ = " ${ version.padRight(primaryVersionPrefixLengthMap.get (currentPrimaryVersion))} "
104+ commitHeader+ = " ${ version.padRight(primaryVersionPrefixLengthMap.getOrDefault (currentPrimaryVersion, 0 ))} "
105105 }
106106 }
107107
@@ -153,7 +153,8 @@ class ChangelogUtils {
153153 return remoteBranches. stream()
154154 .filter(branch -> branch. getObjectId(). getName() != headCommit. toObjectId(). getName())
155155 .map(branch -> getMergeBase(git, branch))
156- .filter(revCommit -> revCommit. toObjectId(). getName() != headCommit. toObjectId(). getName())
156+ .filter(revCommit -> (revCommit != = null ) &&
157+ (revCommit. toObjectId(). getName() != headCommit. toObjectId(). getName()))
157158 .sorted(Comparator . comparing(new Function<RevCommit , Integer > () {
158159 @Override
159160 Integer apply (final RevCommit revCommit ) {
@@ -621,4 +622,4 @@ class ChangelogUtils {
621622 extension = ' txt'
622623 }
623624 }
624- }
625+ }
You can’t perform that action at this time.
0 commit comments