Unwrapped MoveDirectory, DirectoryExists, FileExists & removed MoveFile

This commit is contained in:
Erwin de Haan
2019-01-26 22:59:53 +01:00
parent a430568082
commit 581a7fe078
38 changed files with 89 additions and 87 deletions

View File

@@ -168,14 +168,14 @@ namespace MediaBrowser.Controller.Entities
var oldConfigurationDirectory = ConfigurationDirectoryPath;
// Exceptions will be thrown if these paths already exist
if (FileSystem.DirectoryExists(newConfigDirectory))
if (Directory.Exists(newConfigDirectory))
{
Directory.Delete(newConfigDirectory, true);
}
if (FileSystem.DirectoryExists(oldConfigurationDirectory))
if (Directory.Exists(oldConfigurationDirectory))
{
FileSystem.MoveDirectory(oldConfigurationDirectory, newConfigDirectory);
Directory.Move(oldConfigurationDirectory, newConfigDirectory);
}
else
{