Merge branch '3.1.x'

pull/36767/head
Andy Wilkinson 1 year ago
commit 8ae8fdca57

@ -188,9 +188,12 @@ public abstract class UpgradeDependencies extends DefaultTask {
private Issue findExistingUpgradeIssue(List<Issue> existingUpgradeIssues, Upgrade upgrade) {
String toMatch = "Upgrade to " + upgrade.getLibrary().getName();
for (Issue existingUpgradeIssue : existingUpgradeIssues) {
if (existingUpgradeIssue.getTitle()
.substring(0, existingUpgradeIssue.getTitle().lastIndexOf(' '))
.equals(toMatch)) {
String title = existingUpgradeIssue.getTitle();
int lastSpaceIndex = title.lastIndexOf(' ');
if (lastSpaceIndex > -1) {
title = title.substring(0, lastSpaceIndex);
}
if (title.equals(toMatch)) {
return existingUpgradeIssue;
}
}

Loading…
Cancel
Save