aboutsummaryrefslogtreecommitdiff
path: root/MediaBrowser.Server.Implementations/Devices/DeviceManager.cs
diff options
context:
space:
mode:
Diffstat (limited to 'MediaBrowser.Server.Implementations/Devices/DeviceManager.cs')
-rw-r--r--MediaBrowser.Server.Implementations/Devices/DeviceManager.cs10
1 files changed, 8 insertions, 2 deletions
diff --git a/MediaBrowser.Server.Implementations/Devices/DeviceManager.cs b/MediaBrowser.Server.Implementations/Devices/DeviceManager.cs
index 0173f2784..0b2c082a8 100644
--- a/MediaBrowser.Server.Implementations/Devices/DeviceManager.cs
+++ b/MediaBrowser.Server.Implementations/Devices/DeviceManager.cs
@@ -17,6 +17,7 @@ using System.Collections.Generic;
using System.IO;
using System.Linq;
using System.Threading.Tasks;
+using CommonIO;
namespace MediaBrowser.Server.Implementations.Devices
{
@@ -157,7 +158,7 @@ namespace MediaBrowser.Server.Implementations.Devices
_libraryMonitor.ReportFileSystemChangeBeginning(path);
- Directory.CreateDirectory(Path.GetDirectoryName(path));
+ _fileSystem.CreateDirectory(Path.GetDirectoryName(path));
try
{
@@ -264,6 +265,11 @@ namespace MediaBrowser.Server.Implementations.Devices
return true;
}
+ if (policy.IsAdministrator)
+ {
+ return true;
+ }
+
return ListHelper.ContainsIgnoreCase(policy.EnabledDevices, id);
}
}
@@ -290,4 +296,4 @@ namespace MediaBrowser.Server.Implementations.Devices
return config.GetConfiguration<DevicesOptions>("devices");
}
}
-}
+} \ No newline at end of file