Octopus.Client.Model.Versioning.StrictSemanticVersion.NormalizeVersionValue C# (CSharp) Method

NormalizeVersionValue() static private method

static private NormalizeVersionValue ( System.Version version ) : System.Version
version System.Version
return System.Version
        internal static Version NormalizeVersionValue(Version version)
        {
            var normalized = version;

            if (version.Build < 0
                || version.Revision < 0)
            {
                normalized = new Version(
                    version.Major,
                    version.Minor,
                    Math.Max(version.Build, 0),
                    Math.Max(version.Revision, 0));
            }

            return normalized;
        }