diff --git a/DICUI.Library/Utilities/Validators.cs b/DICUI.Library/Utilities/Validators.cs
index 2927c70d..22b38516 100644
--- a/DICUI.Library/Utilities/Validators.cs
+++ b/DICUI.Library/Utilities/Validators.cs
@@ -804,17 +804,17 @@ namespace DICUI.Utilities
}
///
- /// Get the current system from drive letter
+ /// Get the current system from drive
///
- ///
+ ///
///
- public static KnownSystem? GetKnownSystem(char? driveLetter)
+ public static KnownSystem? GetKnownSystem(Drive drive)
{
- // If no letter is provided, then we can't do anything
- if (driveLetter == null)
+ // If drive or drive letter are provided, we can't do anything
+ if (drive?.Letter == null)
return null;
- string drivePath = $"{driveLetter}:\\";
+ string drivePath = $"{drive.Letter}:\\";
// If we can't read the media in that drive, we can't do anything
if (!Directory.Exists(drivePath))
@@ -856,7 +856,7 @@ namespace DICUI.Utilities
}
// Sony PlayStation 4
- if (File.Exists(Path.Combine(drivePath, "PSLogo.ico")))
+ if (drive.VolumeLabel.Equals("PS4VOLUME", StringComparison.OrdinalIgnoreCase))
{
return KnownSystem.SonyPlayStation4;
}
diff --git a/DICUI/Windows/MainWindow.xaml.cs b/DICUI/Windows/MainWindow.xaml.cs
index 4493fa3b..f4986852 100644
--- a/DICUI/Windows/MainWindow.xaml.cs
+++ b/DICUI/Windows/MainWindow.xaml.cs
@@ -341,7 +341,7 @@ namespace DICUI.Windows
if (!_options.SkipSystemDetection && index != -1)
{
ViewModels.LoggerViewModel.VerboseLog("Trying to detect system for drive {0}.. ", _drives[index].Letter);
- var currentSystem = Validators.GetKnownSystem(_drives[index].Letter);
+ var currentSystem = Validators.GetKnownSystem(_drives[index]);
ViewModels.LoggerViewModel.VerboseLogLn(currentSystem == null || currentSystem == KnownSystem.NONE ? "unable to detect." : ("detected " + currentSystem.LongName() + "."));
if (currentSystem != null && currentSystem != KnownSystem.NONE)