From ea52db551318e131130712804f1dbd2f732da518 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Tue, 26 Sep 2023 21:09:24 +0000 Subject: [PATCH] Bump YamlDotNet from 13.3.1 to 13.4.0 (#180) --- BadDicom/BadDicom.csproj | 7 ++----- BadMedicine.Dicom/FileSystemLayoutProvider.cs | 12 ++++++------ 2 files changed, 8 insertions(+), 11 deletions(-) diff --git a/BadDicom/BadDicom.csproj b/BadDicom/BadDicom.csproj index cf1e0cf..fceb6b4 100644 --- a/BadDicom/BadDicom.csproj +++ b/BadDicom/BadDicom.csproj @@ -1,9 +1,7 @@ - net7.0 true - Exe en @@ -16,7 +14,6 @@ snupkg true enable - true @@ -36,8 +33,8 @@ - - + + diff --git a/BadMedicine.Dicom/FileSystemLayoutProvider.cs b/BadMedicine.Dicom/FileSystemLayoutProvider.cs index f63755a..3f3cb1d 100644 --- a/BadMedicine.Dicom/FileSystemLayoutProvider.cs +++ b/BadMedicine.Dicom/FileSystemLayoutProvider.cs @@ -20,11 +20,11 @@ public FileInfo GetPath(DirectoryInfo root,DicomDataset ds) switch(Layout) { - case FileSystemLayout.Flat: + case FileSystemLayout.Flat: return new FileInfo(Path.Combine(root.FullName,filename)); case FileSystemLayout.StudyYearMonthDay: - + if(date.Length > 0) { return new FileInfo(Path.Combine( @@ -37,9 +37,9 @@ public FileInfo GetPath(DirectoryInfo root,DicomDataset ds) break; case FileSystemLayout.StudyYearMonthDayAccession: - + var acc = ds.GetSingleValue(DicomTag.AccessionNumber); - + if(date.Length > 0 && !string.IsNullOrWhiteSpace(acc)) { return new FileInfo(Path.Combine( @@ -59,9 +59,9 @@ public FileInfo GetPath(DirectoryInfo root,DicomDataset ds) ds.GetSingleValue(DicomTag.StudyInstanceUID).UID, filename)); - default: throw new ArgumentOutOfRangeException(); + default: throw new ArgumentOutOfRangeException(nameof(Layout)); } - + return new FileInfo(Path.Combine(root.FullName,filename)); }