Skip to content

Commit

Permalink
use nameof instead of strings
Browse files Browse the repository at this point in the history
  • Loading branch information
rkm committed Oct 10, 2024
1 parent 9e318f2 commit 83dc691
Showing 1 changed file with 3 additions and 3 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -8,9 +8,9 @@ public static IProjectPathResolver Create(string projectPathResolverType, IFileS
{
return projectPathResolverType switch
{
"StudySeriesSOPProjectPathResolver" => new StudySeriesSOPProjectPathResolver(fileSystem),
"NoSuffixProjectPathResolver" => new NoSuffixProjectPathResolver(fileSystem),
"StudySeriesOriginalFilenameProjectPathResolver" => new StudySeriesOriginalFilenameProjectPathResolver(fileSystem),
nameof(StudySeriesSOPProjectPathResolver) => new StudySeriesSOPProjectPathResolver(fileSystem),
nameof(NoSuffixProjectPathResolver) => new NoSuffixProjectPathResolver(fileSystem),
nameof(StudySeriesOriginalFilenameProjectPathResolver) => new StudySeriesOriginalFilenameProjectPathResolver(fileSystem),
_ => throw new NotImplementedException($"No case for IProjectPathResolver type '{projectPathResolverType}'"),
};
}
Expand Down

0 comments on commit 83dc691

Please sign in to comment.