Merge pull request #19640 from ahrtr/cv_20250321

Returns the string representation of the `ClusterVersion`
This commit is contained in:
Benjamin Wang 2025-03-22 07:48:13 +00:00 committed by GitHub
commit fd4fc82d40
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

View File

@ -23,6 +23,13 @@ const (
LastVersion ClusterVersion = "last-version" LastVersion ClusterVersion = "last-version"
) )
func (cv ClusterVersion) String() string {
if cv == CurrentVersion {
return "current-version"
}
return string(cv)
}
type ClusterContext struct { type ClusterContext struct {
Version ClusterVersion Version ClusterVersion
} }