Skip to content
This repository was archived by the owner on Dec 5, 2024. It is now read-only.

Commit 314c883

Browse files
Adding ToString
1 parent fbe4d82 commit 314c883

File tree

1 file changed

+7
-0
lines changed

1 file changed

+7
-0
lines changed

src/GitHub.Api/OutputProcessors/SoftwareVersion.cs

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -94,5 +94,12 @@ public SoftwareVersion(string major, string minor, string build) :
9494
{
9595
return lhs.Equals(rhs) || lhs > rhs;
9696
}
97+
98+
public override string ToString()
99+
{
100+
return this == Undefined
101+
? "Undefined"
102+
: $"{Major}.{Minor}.{Build}";
103+
}
97104
}
98105
}

0 commit comments

Comments
 (0)