Skip to content

Commit 8ebfbdf

Browse files
committed
Fixing nul ref. version bump
1 parent 22c88f8 commit 8ebfbdf

File tree

2 files changed

+3
-3
lines changed

2 files changed

+3
-3
lines changed

pom.xml

+2-2
Original file line numberDiff line numberDiff line change
@@ -4,8 +4,8 @@
44
<groupId>petegoo.teamcity.plugins.tcslacknotifications</groupId>
55
<artifactId>tcslackbuildnotifier</artifactId>
66
<properties>
7-
<majorVersion>0.9</majorVersion>
8-
<minorVersion>2</minorVersion>
7+
<majorVersion>1.0</majorVersion>
8+
<minorVersion>0</minorVersion>
99
<currentVersion>${majorVersion}.${minorVersion}</currentVersion>
1010
</properties>
1111
<version>${currentVersion}</version>

tcslackbuildnotifier-core/src/main/java/slacknotifications/teamcity/payload/content/SlackNotificationPayloadContent.java

+1-1
Original file line numberDiff line numberDiff line change
@@ -213,7 +213,7 @@ private void populateCommonContent(SBuildServer server, SRunningBuild sRunningBu
213213
Loggers.SERVER.debug("SlackNotificationPayloadContent :: Could not get Branch Info by calling sRunningBuild.getBranch(). Probably an old version of TeamCity");
214214
}
215215
setBuildStatusUrl(server.getRootUrl() + "/viewLog.html?buildTypeId=" + getBuildTypeId() + "&buildId=" + getBuildId());
216-
String branchSuffix = getBranchIsDefault() ? "" : " [" + getBranchDisplayName() + "]";
216+
String branchSuffix = getBranchIsDefault() != null && getBranchIsDefault() ? "" : (" [" + getBranchDisplayName() + "]");
217217
setBuildDescriptionWithLinkSyntax(String.format("<" + getBuildStatusUrl() + "|" + sRunningBuild.getBuildType().getFullName().toString() + " #" + sRunningBuild.getBuildNumber() + branchSuffix + ">"));
218218
setBuildStateDescription(buildState.getDescriptionSuffix());
219219
setRootUrl(server.getRootUrl());

0 commit comments

Comments
 (0)