Skip to content

Commit f019dc4

Browse files
committed
Avoid blowing up if null string are passes to Escape
1 parent cf6dd21 commit f019dc4

File tree

1 file changed

+4
-0
lines changed

1 file changed

+4
-0
lines changed

GitFlowVersion/BuildServers/TeamCity.cs

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -32,6 +32,10 @@ public string GenerateSetVersionMessage(string versionToUseForBuildNumber)
3232

3333
static string EscapeValue(string value)
3434
{
35+
if (value == null)
36+
{
37+
return null;
38+
}
3539
// List of escape values from http://confluence.jetbrains.com/display/TCD8/Build+Script+Interaction+with+TeamCity
3640

3741
value = value.Replace("|", "||");

0 commit comments

Comments
 (0)