Skip to content

Commit

Permalink
Testing
Browse files Browse the repository at this point in the history
  • Loading branch information
tleed5 committed Jan 11, 2024
1 parent fb11c40 commit ef401f3
Showing 1 changed file with 2 additions and 6 deletions.
8 changes: 2 additions & 6 deletions source/Octopus.Versioning/VersionFactory.cs
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ namespace Octopus.Versioning
{
public static class VersionFactory
{
public static IVersion CreateVersion(string input, VersionFormat format)
public static ISortableVersion CreateVersion(string input, VersionFormat format)
{
switch (format)
{
Expand All @@ -20,14 +20,12 @@ public static IVersion CreateVersion(string input, VersionFormat format)
return CreateDockerTag(input);
case VersionFormat.Octopus:
return CreateOctopusVersion(input);
case VersionFormat.Unsortable:
return CreateUnsortableVersion(input);
default:
return CreateSemanticVersion(input);
}
}

public static IVersion? TryCreateVersion(string input, VersionFormat format)
public static ISortableVersion? TryCreateVersion(string input, VersionFormat format)
{
switch (format)
{
Expand All @@ -37,8 +35,6 @@ public static IVersion CreateVersion(string input, VersionFormat format)
return TryCreateDockerTag(input);
case VersionFormat.Octopus:
return TryCreateOctopusVersion(input);
case VersionFormat.Unsortable:
return TryCreateUnsortableVersion(input);
default:
return TryCreateSemanticVersion(input);
}
Expand Down

0 comments on commit ef401f3

Please sign in to comment.