diff --git a/MediaBrowser.Controller/Dto/DtoBuilder.cs b/MediaBrowser.Controller/Dto/DtoBuilder.cs
index a5b7b72ce3..63d19a662d 100644
--- a/MediaBrowser.Controller/Dto/DtoBuilder.cs
+++ b/MediaBrowser.Controller/Dto/DtoBuilder.cs
@@ -299,12 +299,9 @@ namespace MediaBrowser.Controller.Dto
foreach (var image in item.Images)
{
- ImageType type;
+ var type = image.Key;
- if (Enum.TryParse(image.Key, true, out type))
- {
- dto.ImageTags[type] = Kernel.Instance.ImageManager.GetImageCacheTag(item, type, image.Value);
- }
+ dto.ImageTags[type] = Kernel.Instance.ImageManager.GetImageCacheTag(item, type, image.Value);
}
}
diff --git a/MediaBrowser.Controller/Entities/Audio/MusicAlbum.cs b/MediaBrowser.Controller/Entities/Audio/MusicAlbum.cs
index 859910ae69..0366af8c76 100644
--- a/MediaBrowser.Controller/Entities/Audio/MusicAlbum.cs
+++ b/MediaBrowser.Controller/Entities/Audio/MusicAlbum.cs
@@ -111,14 +111,14 @@ namespace MediaBrowser.Controller.Entities.Audio
/// Gets or sets the images.
///
/// The images.
- public override Dictionary Images
+ public override Dictionary Images
{
get
{
var images = base.Images;
string primaryImagePath;
- if (images == null || !images.TryGetValue(ImageType.Primary.ToString(), out primaryImagePath))
+ if (images == null || !images.TryGetValue(ImageType.Primary, out primaryImagePath))
{
var image = Children.Select(c => c.PrimaryImagePath).FirstOrDefault(c => !string.IsNullOrEmpty(c));
@@ -126,9 +126,9 @@ namespace MediaBrowser.Controller.Entities.Audio
{
if (images == null)
{
- images = new Dictionary();
+ images = new Dictionary();
}
- images[ImageType.Primary.ToString()] = image;
+ images[ImageType.Primary] = image;
}
}
diff --git a/MediaBrowser.Controller/Entities/BaseItem.cs b/MediaBrowser.Controller/Entities/BaseItem.cs
index c59094cbfb..c93923ab95 100644
--- a/MediaBrowser.Controller/Entities/BaseItem.cs
+++ b/MediaBrowser.Controller/Entities/BaseItem.cs
@@ -89,7 +89,7 @@ namespace MediaBrowser.Controller.Entities
/// Gets or sets the images.
///
/// The images.
- public virtual Dictionary Images { get; set; }
+ public virtual Dictionary Images { get; set; }
///
/// Gets or sets the date created.
@@ -650,7 +650,7 @@ namespace MediaBrowser.Controller.Entities
///
/// The _local trailers
///
- private List
/// The local trailers.
[IgnoreDataMember]
- public List