mirror of
https://github.com/jellyfin/jellyfin.git
synced 2026-04-17 15:53:42 +01:00
update legacy hd homerun support
This commit is contained in:
@@ -409,18 +409,41 @@ namespace Emby.Server.Implementations.Library
|
||||
|
||||
if (options.DeleteFileLocation && locationType != LocationType.Remote && locationType != LocationType.Virtual)
|
||||
{
|
||||
// Assume only the first is required
|
||||
// Add this flag to GetDeletePaths if required in the future
|
||||
var isRequiredForDelete = true;
|
||||
|
||||
foreach (var fileSystemInfo in item.GetDeletePaths().ToList())
|
||||
{
|
||||
if (fileSystemInfo.IsDirectory)
|
||||
try
|
||||
{
|
||||
_logger.Debug("Deleting path {0}", fileSystemInfo.FullName);
|
||||
_fileSystem.DeleteDirectory(fileSystemInfo.FullName, true);
|
||||
if (fileSystemInfo.IsDirectory)
|
||||
{
|
||||
_logger.Debug("Deleting path {0}", fileSystemInfo.FullName);
|
||||
_fileSystem.DeleteDirectory(fileSystemInfo.FullName, true);
|
||||
}
|
||||
else
|
||||
{
|
||||
_logger.Debug("Deleting path {0}", fileSystemInfo.FullName);
|
||||
_fileSystem.DeleteFile(fileSystemInfo.FullName);
|
||||
}
|
||||
}
|
||||
else
|
||||
catch (IOException)
|
||||
{
|
||||
_logger.Debug("Deleting path {0}", fileSystemInfo.FullName);
|
||||
_fileSystem.DeleteFile(fileSystemInfo.FullName);
|
||||
if (isRequiredForDelete)
|
||||
{
|
||||
throw;
|
||||
}
|
||||
}
|
||||
catch (UnauthorizedAccessException)
|
||||
{
|
||||
if (isRequiredForDelete)
|
||||
{
|
||||
throw;
|
||||
}
|
||||
}
|
||||
|
||||
isRequiredForDelete = false;
|
||||
}
|
||||
|
||||
if (parent != null)
|
||||
|
||||
@@ -434,6 +434,11 @@ namespace Emby.Server.Implementations.Library
|
||||
Policy = user.Policy
|
||||
};
|
||||
|
||||
if (!hasPassword && Users.Count() == 1)
|
||||
{
|
||||
dto.EnableAutoLogin = true;
|
||||
}
|
||||
|
||||
var image = user.GetImageInfo(ImageType.Primary, 0);
|
||||
|
||||
if (image != null)
|
||||
|
||||
Reference in New Issue
Block a user