aboutsummaryrefslogtreecommitdiff
path: root/Emby.Server.Implementations/IO/LibraryMonitor.cs
diff options
context:
space:
mode:
authorLogicalPhallacy <44458166+LogicalPhallacy@users.noreply.github.com>2019-03-16 00:25:16 -0700
committerGitHub <noreply@github.com>2019-03-16 00:25:16 -0700
commit2d0844b5dbf08869896c5479c10675c4fe7fa988 (patch)
treedea28b14d2b1733edf1a90a46f4163f6123616fe /Emby.Server.Implementations/IO/LibraryMonitor.cs
parent221389089cc9ca4b69907d6bf3e9d38bf94393ea (diff)
parent59031ee3b8b2ac8298c41f9171b658e3f15e17bc (diff)
Merge pull request #1 from jellyfin/master
merging myself to latest
Diffstat (limited to 'Emby.Server.Implementations/IO/LibraryMonitor.cs')
-rw-r--r--Emby.Server.Implementations/IO/LibraryMonitor.cs15
1 files changed, 3 insertions, 12 deletions
diff --git a/Emby.Server.Implementations/IO/LibraryMonitor.cs b/Emby.Server.Implementations/IO/LibraryMonitor.cs
index d47342511..df4dc41b9 100644
--- a/Emby.Server.Implementations/IO/LibraryMonitor.cs
+++ b/Emby.Server.Implementations/IO/LibraryMonitor.cs
@@ -10,8 +10,8 @@ using MediaBrowser.Controller.Library;
using MediaBrowser.Controller.Plugins;
using MediaBrowser.Model.IO;
using MediaBrowser.Model.System;
-using MediaBrowser.Model.Tasks;
using Microsoft.Extensions.Logging;
+using OperatingSystem = MediaBrowser.Common.System.OperatingSystem;
namespace Emby.Server.Implementations.IO
{
@@ -127,7 +127,6 @@ namespace Emby.Server.Implementations.IO
private IServerConfigurationManager ConfigurationManager { get; set; }
private readonly IFileSystem _fileSystem;
- private readonly IEnvironmentInfo _environmentInfo;
/// <summary>
/// Initializes a new instance of the <see cref="LibraryMonitor" /> class.
@@ -136,14 +135,12 @@ namespace Emby.Server.Implementations.IO
ILoggerFactory loggerFactory,
ILibraryManager libraryManager,
IServerConfigurationManager configurationManager,
- IFileSystem fileSystem,
- IEnvironmentInfo environmentInfo)
+ IFileSystem fileSystem)
{
LibraryManager = libraryManager;
Logger = loggerFactory.CreateLogger(GetType().Name);
ConfigurationManager = configurationManager;
_fileSystem = fileSystem;
- _environmentInfo = environmentInfo;
}
private bool IsLibraryMonitorEnabled(BaseItem item)
@@ -267,7 +264,7 @@ namespace Emby.Server.Implementations.IO
return;
}
- if (_environmentInfo.OperatingSystem != MediaBrowser.Model.System.OperatingSystem.Windows)
+ if (OperatingSystem.Id != OperatingSystemId.Windows)
{
if (path.StartsWith("\\\\", StringComparison.OrdinalIgnoreCase) || path.StartsWith("smb://", StringComparison.OrdinalIgnoreCase))
{
@@ -276,12 +273,6 @@ namespace Emby.Server.Implementations.IO
}
}
- if (_environmentInfo.OperatingSystem == MediaBrowser.Model.System.OperatingSystem.Android)
- {
- // causing crashing
- return;
- }
-
// Already being watched
if (_fileSystemWatchers.ContainsKey(path))
{