diff options
| author | Luke Pulverenti <luke.pulverenti@gmail.com> | 2016-08-16 13:08:37 -0400 |
|---|---|---|
| committer | Luke Pulverenti <luke.pulverenti@gmail.com> | 2016-08-16 13:08:37 -0400 |
| commit | 8a7b24000da7a9e917ea041095b55fc95e98a17c (patch) | |
| tree | dbd1155c0585e8336667c8e5191f196fa682d107 /MediaBrowser.Server.Implementations | |
| parent | 184d4470239fcec3a46b602f44c742d32a7c2ac1 (diff) | |
update season queries
Diffstat (limited to 'MediaBrowser.Server.Implementations')
| -rw-r--r-- | MediaBrowser.Server.Implementations/Dto/DtoService.cs | 2 | ||||
| -rw-r--r-- | MediaBrowser.Server.Implementations/IO/LibraryMonitor.cs | 14 |
2 files changed, 13 insertions, 3 deletions
diff --git a/MediaBrowser.Server.Implementations/Dto/DtoService.cs b/MediaBrowser.Server.Implementations/Dto/DtoService.cs index 4f903a2c2..b646605ed 100644 --- a/MediaBrowser.Server.Implementations/Dto/DtoService.cs +++ b/MediaBrowser.Server.Implementations/Dto/DtoService.cs @@ -458,7 +458,7 @@ namespace MediaBrowser.Server.Implementations.Dto dto.UserData = await _userDataRepository.GetUserDataDto(item, dto, user).ConfigureAwait(false); - if (item.SourceType == SourceType.Library) + if (!dto.ChildCount.HasValue && item.SourceType == SourceType.Library) { dto.ChildCount = GetChildCount(folder, user); } diff --git a/MediaBrowser.Server.Implementations/IO/LibraryMonitor.cs b/MediaBrowser.Server.Implementations/IO/LibraryMonitor.cs index 8c2b927e3..dea0a978b 100644 --- a/MediaBrowser.Server.Implementations/IO/LibraryMonitor.cs +++ b/MediaBrowser.Server.Implementations/IO/LibraryMonitor.cs @@ -38,7 +38,6 @@ namespace MediaBrowser.Server.Implementations.IO /// </summary> private readonly IReadOnlyList<string> _alwaysIgnoreFiles = new List<string> { - "thumbs.db", "small.jpg", "albumart.jpg", @@ -47,6 +46,15 @@ namespace MediaBrowser.Server.Implementations.IO "TempSBE" }; + private readonly IReadOnlyList<string> _alwaysIgnoreExtensions = new List<string> + { + // thumbs.db + ".db", + + // bts sync files + ".bts" + }; + /// <summary> /// Add the path to our temporary ignore list. Use when writing to a path within our listening scope. /// </summary> @@ -411,7 +419,9 @@ namespace MediaBrowser.Server.Implementations.IO var filename = Path.GetFileName(path); - var monitorPath = !(!string.IsNullOrEmpty(filename) && _alwaysIgnoreFiles.Contains(filename, StringComparer.OrdinalIgnoreCase)); + var monitorPath = !string.IsNullOrEmpty(filename) && + !_alwaysIgnoreFiles.Contains(filename, StringComparer.OrdinalIgnoreCase) && + !_alwaysIgnoreExtensions.Contains(Path.GetExtension(path) ?? string.Empty, StringComparer.OrdinalIgnoreCase); // Ignore certain files var tempIgnorePaths = _tempIgnoredPaths.Keys.ToList(); |
