mirror of
https://github.com/Radarr/Radarr
synced 2025-02-26 16:13:19 +00:00
Don't blow if driveFormat is null when looking up DriveType
Closes #1444
This commit is contained in:
parent
2d54ca5d47
commit
6ac9e5ec18
1 changed files with 5 additions and 0 deletions
|
@ -14,6 +14,11 @@ public static class FindDriveType
|
||||||
|
|
||||||
public static DriveType Find(string driveFormat)
|
public static DriveType Find(string driveFormat)
|
||||||
{
|
{
|
||||||
|
if (driveFormat.IsNullOrWhiteSpace())
|
||||||
|
{
|
||||||
|
return DriveType.Unknown;
|
||||||
|
}
|
||||||
|
|
||||||
return DriveTypeMap.GetValueOrDefault(driveFormat);
|
return DriveTypeMap.GetValueOrDefault(driveFormat);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue