mirror of
https://github.com/jellyfin/jellyfin.git
synced 2026-03-06 18:26:33 +00:00
try to fix unhandled exception in file refresher
This commit is contained in:
@@ -45,6 +45,11 @@ namespace MediaBrowser.Server.Implementations.IO
|
||||
|
||||
private void AddAffectedPath(string path)
|
||||
{
|
||||
if (string.IsNullOrWhiteSpace(path))
|
||||
{
|
||||
throw new ArgumentNullException("path");
|
||||
}
|
||||
|
||||
if (!_affectedPaths.Contains(path, StringComparer.Ordinal))
|
||||
{
|
||||
_affectedPaths.Add(path);
|
||||
@@ -53,6 +58,11 @@ namespace MediaBrowser.Server.Implementations.IO
|
||||
|
||||
public void AddPath(string path)
|
||||
{
|
||||
if (string.IsNullOrWhiteSpace(path))
|
||||
{
|
||||
throw new ArgumentNullException("path");
|
||||
}
|
||||
|
||||
lock (_timerLock)
|
||||
{
|
||||
AddAffectedPath(path);
|
||||
|
||||
Reference in New Issue
Block a user