diff options
Diffstat (limited to 'Emby.Server.Implementations/Dto/DtoService.cs')
| -rw-r--r-- | Emby.Server.Implementations/Dto/DtoService.cs | 24 |
1 files changed, 15 insertions, 9 deletions
diff --git a/Emby.Server.Implementations/Dto/DtoService.cs b/Emby.Server.Implementations/Dto/DtoService.cs index 45fbd69dc..6bf58455f 100644 --- a/Emby.Server.Implementations/Dto/DtoService.cs +++ b/Emby.Server.Implementations/Dto/DtoService.cs @@ -1058,11 +1058,6 @@ namespace Emby.Server.Implementations.Dto dto.CommunityRating = item.CommunityRating; } - if (fields.Contains(ItemFields.VoteCount)) - { - dto.VoteCount = item.VoteCount; - } - //if (item.IsFolder) //{ // var folder = (Folder)item; @@ -1084,7 +1079,10 @@ namespace Emby.Server.Implementations.Dto if (audio != null) { dto.Album = audio.Album; - dto.ExtraType = audio.ExtraType; + if (audio.ExtraType.HasValue) + { + dto.ExtraType = audio.ExtraType.Value.ToString(); + } var albumParent = audio.AlbumEntity; @@ -1239,7 +1237,10 @@ namespace Emby.Server.Implementations.Dto dto.Chapters = GetChapterInfoDtos(item); } - dto.ExtraType = video.ExtraType; + if (video.ExtraType.HasValue) + { + dto.ExtraType = video.ExtraType.Value.ToString(); + } } if (fields.Contains(ItemFields.MediaStreams)) @@ -1395,7 +1396,7 @@ namespace Emby.Server.Implementations.Dto } } - if (fields.Contains(ItemFields.SeriesPrimaryImage)) + //if (fields.Contains(ItemFields.SeriesPrimaryImage)) { series = series ?? season.Series; if (series != null) @@ -1586,7 +1587,7 @@ namespace Emby.Server.Implementations.Dto { var imageInfo = item.GetImageInfo(ImageType.Primary, 0); - if (imageInfo == null || !imageInfo.IsLocalFile) + if (imageInfo == null) { return null; } @@ -1610,6 +1611,11 @@ namespace Emby.Server.Implementations.Dto } else { + if (!imageInfo.IsLocalFile) + { + return null; + } + try { size = _imageProcessor.GetImageSize(imageInfo); |
