diff --git a/MediaBrowser.Api/Library/LibraryHelpers.cs b/MediaBrowser.Api/Library/LibraryHelpers.cs
index c18c90b200..111922bcad 100644
--- a/MediaBrowser.Api/Library/LibraryHelpers.cs
+++ b/MediaBrowser.Api/Library/LibraryHelpers.cs
@@ -54,8 +54,6 @@ namespace MediaBrowser.Api.Library
/// Name of the virtual folder.
/// The path.
/// The app paths.
- /// The path does not exist.
- /// The path is not valid.
public static void AddMediaPath(IFileSystem fileSystem, string virtualFolderName, string path, IServerApplicationPaths appPaths)
{
if (!fileSystem.DirectoryExists(path))
diff --git a/MediaBrowser.Api/Library/LibraryStructureService.cs b/MediaBrowser.Api/Library/LibraryStructureService.cs
index 42c6ef6e5a..96af5240ef 100644
--- a/MediaBrowser.Api/Library/LibraryStructureService.cs
+++ b/MediaBrowser.Api/Library/LibraryStructureService.cs
@@ -47,6 +47,12 @@ namespace MediaBrowser.Api.Library
///
/// true if [refresh library]; otherwise, false.
public bool RefreshLibrary { get; set; }
+
+ ///
+ /// Gets or sets the path.
+ ///
+ /// The path.
+ public string Path { get; set; }
}
[Route("/Library/VirtualFolders", "DELETE")]
@@ -216,6 +222,11 @@ namespace MediaBrowser.Api.Library
}
}
+
+ if (!string.IsNullOrWhiteSpace(request.Path))
+ {
+ LibraryHelpers.AddMediaPath(_fileSystem, request.Name, request.Path, _appPaths);
+ }
}
finally
{
diff --git a/MediaBrowser.WebDashboard/MediaBrowser.WebDashboard.csproj b/MediaBrowser.WebDashboard/MediaBrowser.WebDashboard.csproj
index 5759f43dc0..d6754f5971 100644
--- a/MediaBrowser.WebDashboard/MediaBrowser.WebDashboard.csproj
+++ b/MediaBrowser.WebDashboard/MediaBrowser.WebDashboard.csproj
@@ -200,10 +200,10 @@
PreserveNewest
-
+
PreserveNewest
-
+
PreserveNewest