update shared dialogs

pull/702/head
Luke Pulverenti 9 years ago
parent 04d3175473
commit 4837b08e7d

@ -316,7 +316,7 @@ namespace MediaBrowser.WebDashboard.Api
DeleteFilesByExtension(bowerPath, ".txt");
DeleteFilesByExtension(bowerPath, ".map");
DeleteFilesByExtension(bowerPath, ".md");
DeleteFilesByExtension(bowerPath, ".json");
DeleteFilesByExtension(bowerPath, ".json", "strings\\");
DeleteFilesByExtension(bowerPath, ".gz");
DeleteFilesByExtension(bowerPath, ".bat");
DeleteFilesByExtension(bowerPath, ".sh");
@ -401,7 +401,7 @@ namespace MediaBrowser.WebDashboard.Api
}
}
private void DeleteFilesByExtension(string path, string extension)
private void DeleteFilesByExtension(string path, string extension, string exclude = null)
{
var files = _fileSystem.GetFiles(path, true)
.Where(i => string.Equals(i.Extension, extension, StringComparison.OrdinalIgnoreCase))
@ -409,6 +409,13 @@ namespace MediaBrowser.WebDashboard.Api
foreach (var file in files)
{
if (!string.IsNullOrWhiteSpace(exclude))
{
if (file.FullName.IndexOf(exclude, StringComparison.OrdinalIgnoreCase) != -1)
{
continue;
}
}
_fileSystem.DeleteFile(file.FullName);
}
}

Loading…
Cancel
Save